Skip to content

Commit

Permalink
Fix JSON for standings
Browse files Browse the repository at this point in the history
  • Loading branch information
Saturn committed Jan 14, 2019
1 parent 6638f6f commit bd78693
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions soccer/writers.py
Original file line number Diff line number Diff line change
Expand Up @@ -307,11 +307,11 @@ def team_scores(self, team_scores, time):
def standings(self, league_table, league):
"""Store output of league standings to a JSON file"""
data = []
for team in league_table['standing']:
for team in league_table['standings'][0]['table']:
item = {'position': team['position'],
'teamName': team['teamName'],
'teamName': team['team'],
'playedGames': team['playedGames'],
'goalsFor': team['goals'],
'goalsFor': team['goalsFor'],
'goalsAgainst': team['goalsAgainst'],
'goalDifference': team['goalDifference'],
'points': team['points']}
Expand Down

0 comments on commit bd78693

Please sign in to comment.