fix: gameModel.create is not cringe now
This commit is contained in:
parent
fb0f9be103
commit
0e946b3bb8
@ -6,7 +6,7 @@ class GameModel(models.Model):
|
||||
def create(self, users_id: [int]):
|
||||
self.save()
|
||||
for user_id in users_id:
|
||||
GameMembersModel(game_id=self.pk, member_id=user_id)
|
||||
GameMembersModel(game_id=self.pk, member_id=user_id).save()
|
||||
return self.pk
|
||||
|
||||
class GameMembersModel(models.Model):
|
||||
|
Loading…
Reference in New Issue
Block a user