toJson method

  1. @override
Map<String, dynamic> toJson()
override

Implementation

@override
Map<String, dynamic> toJson() {
  final Map<String, dynamic> data = super.toJson();
  data.putIfNotNull("thumbnailLocalPath", thumbnailLocalPath);
  data.putIfNotNull("thumbnailRemotePath", thumbnailRemotePath);
  data.putIfNotNull("thumbnailSecret", thumbnailSecret);
  data.putIfNotNull("sendOriginalImage", sendOriginalImage);
  data.putIfNotNull("height", height ?? 0.0);
  data.putIfNotNull("width", width ?? 0.0);
  data.putIfNotNull(
      "thumbnailStatus", downloadStatusToInt(this.thumbnailStatus));
  return data;
}