Skip to content

Commit

Permalink
Merge pull request #216 from cwendt94/BbBoxScoreFinalScoringPeriodBug
Browse files Browse the repository at this point in the history
Basketball Box Score Fix Final Scoring Period
  • Loading branch information
cwendt94 authored May 27, 2021
2 parents 19613d7 + bf83d0e commit 1b89f12
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion espn_api/basketball/box_score.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ def __init__(self, data, pro_schedule, by_matchup):
self.home_projected = -1 # week is over/not set
roster_key = 'rosterForMatchupPeriod' if by_matchup else 'rosterForCurrentScoringPeriod'
home_roster = data['home'].get(roster_key, {})
if 'totalPointsLive' in data['home']:
if 'totalPointsLive' in data['home'] and by_matchup:
self.home_score = round(data['home']['totalPointsLive'], 2)
self.home_projected = round(data['home'].get('totalProjectedPointsLive', -1), 2)
else:
Expand Down

0 comments on commit 1b89f12

Please sign in to comment.