Jon Solow commited on
Commit
6c6e34b
·
1 Parent(s): cddb304

Fix order of live schedule and daily schedule

Browse files
Files changed (1) hide show
  1. src/pages/11_Scoreboard.py +6 -2
src/pages/11_Scoreboard.py CHANGED
@@ -36,10 +36,14 @@ def get_daily_updated_schedule() -> dict[int, dict[str, dict[str, str | int | pd
36
 
37
  @st.cache_data(ttl=60 * 5)
38
  def get_schedule_with_live() -> dict[int, dict[str, dict[str, str | int | pd.Timestamp]]]:
39
- schedule = get_daily_updated_schedule()
40
 
41
- for week, week_live in get_live_schedule().items():
 
 
42
  for team, team_live in week_live.items():
 
 
43
  schedule[week][team].update(team_live)
44
 
45
  return schedule
 
36
 
37
  @st.cache_data(ttl=60 * 5)
38
  def get_schedule_with_live() -> dict[int, dict[str, dict[str, str | int | pd.Timestamp]]]:
39
+ schedule = get_live_schedule()
40
 
41
+ for week, week_live in get_daily_updated_schedule().items():
42
+ if week not in schedule:
43
+ schedule[week] = {}
44
  for team, team_live in week_live.items():
45
+ if team not in schedule[week]:
46
+ schedule[week][team] = {}
47
  schedule[week][team].update(team_live)
48
 
49
  return schedule