Skip to content

Commit

Permalink
Merge pull request #5704 from topcoder-platform/gig-referrals-hotfix
Browse files Browse the repository at this point in the history
Gig referrals hotfix
  • Loading branch information
sushilshinde authored Sep 21, 2021
2 parents e16c107 + 3cd7a85 commit a688ac2
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 4 deletions.
3 changes: 1 addition & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -370,8 +370,7 @@ workflows:
filters: &filters-staging
branches:
only:
- develop
- feature/link-thrive
- gig-referrals-hotfix
# Production builds are exectuted
# when PR is merged to the master
# Don't change anything in this configuration
Expand Down
10 changes: 8 additions & 2 deletions src/shared/components/Gigs/ReferralCode/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,10 @@ function ReferralCode(props) {
<React.Fragment>
<span>Your referral link:</span>
{
growSurfState.data ? (
growSurfState.loading && <LoadingIndicator />
}
{
growSurfState.data && (
<div className={defautlStyle.rondedArea}>
<span>{`https://www.topcoder.com/gigs?referralId=${growSurfState.data.id}`}</span>
<PrimaryButton
Expand All @@ -92,7 +95,10 @@ function ReferralCode(props) {
{copyBtnText}
</PrimaryButton>
</div>
) : <LoadingIndicator />
)
}
{
growSurfState.error && <span>Ops, we couldn&apos;t load your profile. Please try again later or contact <a href="mailto:[email protected]">support</a>.</span>
}
</React.Fragment>
)
Expand Down
1 change: 1 addition & 0 deletions src/shared/reducers/growSurf.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ function onDone(state, { payload }) {
...state,
loading: false,
data: payload.data,
error: payload.error || false,
};
}

Expand Down

0 comments on commit a688ac2

Please sign in to comment.