Fix some for iam
This commit is contained in:
@@ -9,9 +9,10 @@ const auth = useAuthStore();
|
||||
|
||||
onMounted(async () => {
|
||||
const params = new URLSearchParams(window.location.search);
|
||||
sessionStorage.setItem('gb_admin_iam_sso_checked', '1');
|
||||
sessionStorage.removeItem('gb_admin_iam_sso_checked');
|
||||
|
||||
if (params.get('error') || !params.get('code') || !params.get('state')) {
|
||||
sessionStorage.setItem('gb_admin_iam_sso_skip', '1');
|
||||
await router.replace('/auth/login');
|
||||
return;
|
||||
}
|
||||
@@ -27,6 +28,7 @@ onMounted(async () => {
|
||||
auth.inject(persisted);
|
||||
await router.replace('/dashboard/ecommerce');
|
||||
} catch {
|
||||
sessionStorage.setItem('gb_admin_iam_sso_skip', '1');
|
||||
await router.replace('/auth/login');
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user