Skip to content

Commit

Permalink
Fix of challenge listing
Browse files Browse the repository at this point in the history
Format of MM objects returned by the backend has changed slightly, and
it broke our frontend code. This is the fix.
  • Loading branch information
birdofpreyru committed Jun 12, 2017
1 parent 6d4cc63 commit 833161e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/shared/reducers/challenge-listing.js
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ export function normalizeMarathonMatch(challenge) {
currentPhases: allphases.filter(phase => phase.phaseStatus === 'Open'),
communities: new Set([COMMUNITY.DATA_SCIENCE]),
currentPhaseName: endTimestamp > Date.now() ? 'Registration' : '',
numRegistrants: challenge.numRegistrants[0],
numSubmissions: challenge.userIds.length,
numRegistrants: challenge.numRegistrants ? challenge.numRegistrants[0] : 0,
numSubmissions: challenge.userIds ? challenge.userIds.length : 0,
platforms: '',
prizes: [0],
registrationOpen: endTimestamp > Date.now() ? 'Yes' : 'No',
Expand Down

0 comments on commit 833161e

Please sign in to comment.