Fixed winrate over time bug

This commit is contained in:
Yarne Coppens 2024-08-31 09:20:16 +02:00
parent 9a181367c1
commit 0529819da8

View file

@ -375,7 +375,7 @@ def get_winrate_over_time(session: Session, player_name: str | None = None, day_
else: else:
timeline_dict[current_date] = 0 timeline_dict[current_date] = 0
current_date == date.today() current_date = date.today()
playplayers_at_date = list(filter(lambda playplayer: playplayer.play.play_date <= current_date, all_playplayers)) playplayers_at_date = list(filter(lambda playplayer: playplayer.play.play_date <= current_date, all_playplayers))
total_games_played = len(playplayers_at_date) total_games_played = len(playplayers_at_date)
total_games_won = 0 total_games_won = 0