Skip to content

Commit 64cf74c

Browse files
committed
fix: use post_login_redirect_uri after login
1 parent 73da4f9 commit 64cf74c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/auth/app_auth_complete/index.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ const SWA_EMU_HOST = "http://localhost:" + process.env.SWA_EMU_PORT;
33

44
module.exports = async function (context, req) {
55
const { provider } = context.bindingData;
6-
const { post_login_redirect_uri } = req.query;
6+
const { post_login_redirect_uri = "" } = req.query;
77

88
context.res = response({
99
context,
@@ -27,7 +27,7 @@ module.exports = async function (context, req) {
2727
},
2828
],
2929
headers: {
30-
location: `${SWA_EMU_HOST}/profile`,
30+
location: `${SWA_EMU_HOST}/${post_login_redirect_uri}`,
3131
},
3232
});
3333
};

0 commit comments

Comments
 (0)