register stat on join
This commit is contained in:
parent
c55b4b81ed
commit
32b9f4491f
1 changed files with 3 additions and 0 deletions
|
@ -64,6 +64,9 @@ class GameManager(object):
|
||||||
|
|
||||||
try:
|
try:
|
||||||
us = UserSetting.get(id=user.id)
|
us = UserSetting.get(id=user.id)
|
||||||
|
if not us:
|
||||||
|
us = UserSetting(id=user.id)
|
||||||
|
|
||||||
us.games_played += 1
|
us.games_played += 1
|
||||||
game = self.chatid_games[chat.id][-1]
|
game = self.chatid_games[chat.id][-1]
|
||||||
except (KeyError, IndexError):
|
except (KeyError, IndexError):
|
||||||
|
|
Loading…
Reference in a new issue