Skip to content

Commit

Permalink
Update base_league.py
Browse files Browse the repository at this point in the history
  • Loading branch information
DesiPilla committed Dec 4, 2023
1 parent 86c2028 commit 8f9a834
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion espn_api/base_league.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ def _fetch_league(self, SettingsClass = BaseSettings):
self.scoringPeriodId = data['scoringPeriodId']
self.firstScoringPeriod = data['status']['firstScoringPeriod']
self.finalScoringPeriod = data['status']['finalScoringPeriod']
self.previousSeasons = data["status"]["previousSeasons"]
self.previousSeasons = [
year for year in data["status"]["previousSeasons"] if year < self.year
]
if self.year < 2018:
self.current_week = data['scoringPeriodId']
else:
Expand Down

0 comments on commit 8f9a834

Please sign in to comment.