Skip to content

Commit 6cf89f5

Browse files
Merge pull request #6549 from topcoder-platform/hotfix/topgear-outage
hotfix: topgear challenges listing page not showing
2 parents 599975b + cd48712 commit 6cf89f5

File tree

3 files changed

+13
-2
lines changed

3 files changed

+13
-2
lines changed

__tests__/shared/components/__snapshots__/Content.jsx.snap

+1-1
Original file line numberDiff line numberDiff line change
@@ -491,7 +491,7 @@ exports[`Matches shallow shapshot 1`] = `
491491
<li>
492492
<Link
493493
replace={false}
494-
to="/__community__/wipro"
494+
to="/__community__/wipro/challenges"
495495
>
496496
TopGear (Wipro) community
497497
</Link>

src/server/services/communities.js

+11
Original file line numberDiff line numberDiff line change
@@ -116,6 +116,17 @@ export async function getMetadata(communityId) {
116116
if (metadata.groupIds) {
117117
metadata.groupIds = await extendByChildGroups(metadata.groupIds);
118118
}
119+
120+
// FIXME: This is a tempory patch to resolve "Backstage Error" that's showing up on Topgear
121+
// app due to missing "Wipro All" authorized group
122+
// Roll this back as soon as the root cause is fixed
123+
// which is likely either in topcoder-react-lib that handles merging groups (https://github.com/topcoder-platform/topcoder-react-lib/blob/c637525211550bea283390e52490fce7f6dd44a8/src/services/groups.js#L107)
124+
// or Groups Api
125+
if (communityId === 'wipro') {
126+
logger.info('Getting metadata for Topgear. Existing Authorized Groups', JSON.stringify(metadata.authorizedGroupIds));
127+
metadata.authorizedGroupIds = _.uniq(metadata.authorizedGroupIds.concat('b7f7c0f8-8ee8-409e-9e5c-33404983b635'));
128+
logger.info('After adding "Wipro All" group', JSON.stringify(metadata.authorizedGroupIds));
129+
}
119130
getMetadata.cache[communityId] = { data: metadata, timestamp: now };
120131
return _.cloneDeep(metadata);
121132
}

src/shared/components/Content/index.jsx

+1-1
Original file line numberDiff line numberDiff line change
@@ -413,7 +413,7 @@ export default function Content() {
413413
</Link>
414414
</li>
415415
<li>
416-
<Link to="/__community__/wipro">
416+
<Link to="/__community__/wipro/challenges">
417417
TopGear (Wipro) community
418418
</Link>
419419
</li>

0 commit comments

Comments
 (0)