toJson method

Map<String, dynamic> toJson()

Implementation

Map<String, dynamic> toJson() {
  final map = <String, dynamic>{};
  map['success'] = success;
  map['message'] = message;
  if (data != null) {
    map['data'] = data?.toJson();
  }
  return map;
}