We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7b6afb8 commit 5a3918eCopy full SHA for 5a3918e
1 file changed
watcher/jobs/snapshots.py
@@ -12,8 +12,10 @@ async def take_player_snapshot():
12
player_sessions = [
13
session for session in sessions if session.player == player.id
14
]
15
- player_town = [town for town in towns if town.id == player.town][0]
+ player_town = [town for town in towns if town.id == player.town]
16
+ player_town = player_town[0] if player_town else None
17
18
+ # TODO: Get rid of storing entire sessions as it is unnecessary
19
sessions_dict = {}
20
for session in player_sessions:
21
sessions_dict[str(session.id)] = {
0 commit comments