fix json serialization nnbd

This commit is contained in:
Salvatore Giordano
2021-04-14 15:34:52 +02:00
parent 45c1e31509
commit 2d11e32700
9 changed files with 24 additions and 23 deletions
@@ -31,11 +31,11 @@ class Event {
}) : isLocal = true;
/// Create a new instance from a json
factory Event.fromJson(Map<String, dynamic>? json) =>
factory Event.fromJson(Map<String, dynamic> json) =>
_$EventFromJson(Serialization.moveToExtraDataFromRoot(
json,
topLevelFields,
)!)
))
..isLocal = false;
/// The type of the event
@@ -197,11 +197,11 @@ class EventChannel extends ChannelModel {
);
/// Create a new instance from a json
factory EventChannel.fromJson(Map<String, dynamic>? json) =>
factory EventChannel.fromJson(Map<String, dynamic> json) =>
_$EventChannelFromJson(Serialization.moveToExtraDataFromRoot(
json,
topLevelFields,
)!);
));
/// A paginated list of channel members
final List<Member>? members;