Skip to content

Commit

Permalink
fix: ref wrong object
Browse files Browse the repository at this point in the history
  • Loading branch information
theClarkSell committed Feb 3, 2022
1 parent f65ca91 commit fafff8b
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/_utils/security/auth.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,9 +78,13 @@ export function initAuth0(config) {
};
}
} else {
const queryString = loadParams.url.searchParams.toString();
const { url } = loadParams;

const queryString = url.searchParams.toString();
const returnUrl =
opts?.returnTo || `${loadParams.url.path}${queryString ? '?' + queryString : ''}`;
opts?.returnTo || `${url.pathname}${queryString ? '?' + queryString : '/'}`;

console.log({ returnUrl });

return {
status: 307,
Expand Down

0 comments on commit fafff8b

Please sign in to comment.