toJSON method Null safety

  1. @override
dynamic toJSON(
  1. dynamic object,
  2. [SerializationContext? context]
)
override

Implementation

@override
dynamic toJSON(dynamic object, [SerializationContext? context]) {
  return object.map((item) => _serializeObject(item)).toList();
}