Changed method name
This commit is contained in:
@@ -24,7 +24,7 @@ class GameDao extends DatabaseAccessor<AppDatabase> with _$GameDaoMixin {
|
||||
final result = await query.getSingle();
|
||||
|
||||
List<Player>? players;
|
||||
if (await db.playerGameDao.hasGamePlayers(gameId: gameId)) {
|
||||
if (await db.playerGameDao.gameHasPlayers(gameId: gameId)) {
|
||||
players = await db.playerGameDao.getPlayersByGameId(gameId: gameId);
|
||||
}
|
||||
Group? group;
|
||||
|
||||
@@ -12,7 +12,7 @@ class PlayerGameDao extends DatabaseAccessor<AppDatabase>
|
||||
|
||||
/// Checks if there are any players associated with the given [gameId].
|
||||
/// Returns `true` if there are players, otherwise `false`.
|
||||
Future<bool> hasGamePlayers({required String gameId}) async {
|
||||
Future<bool> gameHasPlayers({required String gameId}) async {
|
||||
final count =
|
||||
await (selectOnly(playerGameTable)
|
||||
..where(playerGameTable.gameId.equals(gameId))
|
||||
|
||||
Reference in New Issue
Block a user