getRoomWithId static method

Future<RoomModel> getRoomWithId(
  1. String appId,
  2. String roomId
)

Implementation

static Future<RoomModel> getRoomWithId(String appId, String roomId) async {
  var room = await roomRepository(appId: appId)!.get(roomId, onError: (_) {});
  if (room == null) {
    throw Exception('Room with id $roomId for app $appId not found');
  } else {
    return room;
  }
}