getEventById method

  1. @override
Future<Event?> getEventById(
  1. String eventId,
  2. Room room
)
override

Implementation

@override
Future<Event?> getEventById(String eventId, Room room) async {
  final raw = await _eventsBox.get(TupleKey(room.id, eventId).toString());
  if (raw == null) return null;
  return Event.fromJson(copyMap(raw), room);
}