Skip to content

Commit

Permalink
discard known HANDLING_LOGIN_CALLBACK error in hds-react
Browse files Browse the repository at this point in the history
  • Loading branch information
henrinie-nc committed Sep 19, 2024
1 parent 76fcdc7 commit 9e7c1ef
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/auth/components/CallbackPage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,11 @@ const CallbackPage = (props: Props) => {
history.push(getRedirectUrlFromSessionStorage() || getRouteById(Routes.LEASES));
};
const onError = (error: OidcClientError) => {
// "HANDLING_LOGIN_CALLBACK cannot be handled by a callback" is a known error in HDS
// https://hds.hel.fi/components/login/api/#logincallbackhandler
if (error.message === "Current state (HANDLING_LOGIN_CALLBACK) cannot be handled by a callback") {
return;
}
console.error("Login Callback Error:", error);
};

Expand Down

0 comments on commit 9e7c1ef

Please sign in to comment.