MinecraftPatch.fromJson constructor

MinecraftPatch.fromJson(
  1. Map<String, dynamic> data
)

Implementation

MinecraftPatch.fromJson(Map<String, dynamic> data)
    : title = data['title'],
      type = data['type'] == 'release'
          ? MinecraftPatchType.release
          : MinecraftPatchType.snapshot,
      version = data['version'],
      body = data['body'],
      id = data['id'],
      _imageUrl = data['image']['url'],
      imageTitle = data['image']['title'];