From 544b5dd50c35828f20f5381358c0d21cc21c73db Mon Sep 17 00:00:00 2001 From: emkael Date: Sun, 27 Mar 2022 21:50:52 +0200 Subject: Fallback for unknown teams in auto-carryover mode --- jfr_playoff/data/info.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'jfr_playoff') diff --git a/jfr_playoff/data/info.py b/jfr_playoff/data/info.py index fc5121a..6e6f36c 100644 --- a/jfr_playoff/data/info.py +++ b/jfr_playoff/data/info.py @@ -287,7 +287,7 @@ class MatchInfo(ResultInfo): self.info.possible_winner = teams[1] elif self.info.running == 0: if self._auto_carryover: - team_data = [self.teams_by_name[team] for team in teams] + team_data = [self.teams_by_name.get(team, []) for team in teams] if len(team_data[0]) > 4 and len(team_data[1]) > 4: carry_over = self._auto_carryover / Decimal(100.0) * (team_data[0][4] - team_data[1][4]) if carry_over > 0: -- cgit v1.2.3