mirror of
https://github.com/Deathgarden-Rebirth/Deathgarden_Rebirth-Rewrite.git
synced 2026-04-26 02:00:32 -05:00
New check for recent edge case where the matchmaking broke due to a game being stuck on open.
This commit is contained in:
parent
2619344f75
commit
b92c88df09
|
|
@ -368,7 +368,8 @@ protected function removeUserFromGame(User $user, Game $game)
|
|||
{
|
||||
$game->players()->detach($user);
|
||||
|
||||
if($game->players->count() !== 0)
|
||||
// Delete the game if the creator deletes themselfes sice we had one case where the matchmaking broke due to a game being stuck like this.
|
||||
if($game->players->count() !== 0 && $game->creator_user_id !== $user->id)
|
||||
return;
|
||||
|
||||
$game->delete();
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user