Skip to content
This repository was archived by the owner on Mar 13, 2025. It is now read-only.

Commit 2dc320f

Browse files
authored
Merge pull request #299 from afrisalyp/develop
Fix redirect url.
2 parents 5d09872 + 697f72a commit 2dc320f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

src/common/constants.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,8 @@ const GITLAB_REFRESH_TOKEN_BEFORE_EXPIRATION = 300;
5252
const GITHUB_OWNER_CALLBACK_URL = '/api/v1/github/owneruser/callback';
5353
const GITLAB_OWNER_CALLBACK_URL = '/api/v1/gitlab/owneruser/callback';
5454

55-
const OWNER_USER_LOGIN_SUCCESS_URL = '/#/app/settings';
56-
const USER_ADDED_TO_TEAM_SUCCESS_URL = '/#/members';
55+
const OWNER_USER_LOGIN_SUCCESS_URL = '/#!/app/settings';
56+
const USER_ADDED_TO_TEAM_SUCCESS_URL = '/#!/members';
5757

5858
const TC_LOGIN_CALLBACK_URL = '/api/v1/tclogin';
5959
const JWT_V3_NAME = 'v3jwt';

src/controllers/GithubController.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ async function addUserToTeamCallback(req, res) {
196196
// check if user is already in the team or not yet
197197
if (githubUser.state === 'active') {
198198
// redirect user to the success page, to let user know that he is already in the team
199-
const url = `${teamDetails.organization.login}_${teamDetails.name}`;
199+
const url = `${teamDetails.organization.login}_${teamDetails.name.replace(/ /g, '-')}`;
200200
res.redirect(`${constants.USER_ADDED_TO_TEAM_SUCCESS_URL}/github/${url}`);
201201
} else {
202202
// redirect user to organization invitation page

0 commit comments

Comments
 (0)