Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@
"lint:js": "./node_modules/.bin/eslint --ext .js,.jsx .",
"test": "npm run lint && npm run jest"
},
"version": "1000.19.45",
"version": "1000.19.48",
"dependencies": {
"auth0-js": "^6.8.4",
"config": "^3.2.0",
Expand Down
2 changes: 1 addition & 1 deletion src/reducers/challenge.js
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ export function factory(options = {}) {
tokens.tokenV2,
)).then((res) => {
const challengeDetails = _.get(res, 'payload', {});
const track = _.get(challengeDetails, 'legacy.track', '');
const track = _.get(challengeDetails, 'track', '');
let checkpointsPromise = null;
if (track === COMPETITION_TRACKS.DESIGN) {
const p = _.get(challengeDetails, 'phases', [])
Expand Down
6 changes: 4 additions & 2 deletions src/services/challenges.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ export function normalizeChallenge(challenge, username) {
}
const prizes = (challenge.prizeSets[0] && challenge.prizeSets[0].prizes) || [];
_.defaults(challenge, {
communities: new Set([COMPETITION_TRACKS[challenge.legacy.track]]),
communities: new Set([COMPETITION_TRACKS[challenge.track]]),
groups,
registrationOpen,
submissionEndTimestamp,
Expand Down Expand Up @@ -407,7 +407,9 @@ class ChallengesService {
.then(checkErrorV5).then(res => res.result);

/* API will return all roles to currentUser, so need to filter in FE */
registrants = _.filter(registrants, r => r.roleId === roleId);
if (roleId) {
registrants = _.filter(registrants, r => r.roleId === roleId);
}

return registrants || [];
}
Expand Down