BlocklistRow.fromJson constructor

BlocklistRow.fromJson(
  1. Map<String, dynamic> json, {
  2. ValueSerializer? serializer,
})

Implementation

factory BlocklistRow.fromJson(Map<String, dynamic> json,
    {ValueSerializer? serializer}) {
  serializer ??= driftRuntimeOptions.defaultSerializer;
  return BlocklistRow(
    userId: serializer.fromJson<String>(json['userId']),
    reason: serializer.fromJson<String?>(json['reason']),
    at: serializer.fromJson<PreciseDateTime>(json['at']),
    cursor: serializer.fromJson<String?>(json['cursor']),
  );
}