🐛 Fixed store length method

This commit is contained in:
GeoffreyCoulaud
2023-09-26 14:30:39 +02:00
parent 29a3e6e9d3
commit 5f9c990b25

View File

@@ -60,7 +60,7 @@ class Store:
def __len__(self) -> int:
"""Get the number of games in the store with the `len` builtin"""
return sum(len(source_mapping) for source_mapping in self.source_games)
return sum(len(source_mapping) for source_mapping in self.source_games.values())
def __getitem__(self, game_id: str) -> Game:
"""Get a game by its id with `store["game_id_goes_here"]`"""