summaryrefslogtreecommitdiff
path: root/jfr_playoff
diff options
context:
space:
mode:
authoremkael <emkael@tlen.pl>2022-03-27 21:50:52 +0200
committeremkael <emkael@tlen.pl>2022-03-27 21:50:52 +0200
commit544b5dd50c35828f20f5381358c0d21cc21c73db (patch)
treef687a659342a4f6a3b8e5cd6373b714499660877 /jfr_playoff
parent9a3a4cf5ade30c48ca455f92a22acecab151cef8 (diff)
Fallback for unknown teams in auto-carryover mode
Diffstat (limited to 'jfr_playoff')
-rw-r--r--jfr_playoff/data/info.py2
1 files changed, 1 insertions, 1 deletions
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: