2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-02 03:30:54 +00:00

[UI] Incorrect redirect to MFA setup (#9896)

Fixes #9880
This commit is contained in:
Matthias Mair
2025-06-29 00:15:00 +02:00
committed by GitHub
parent ab5765685a
commit ce8ece4f10

View File

@ -55,18 +55,9 @@ export async function fetchGlobalStates(
}
setApiDefaults();
await useServerApiState.getState().fetchServerApiState();
const result = await useUserSettingsState.getState().fetchSettings();
if (!result && navigate) {
console.log('MFA is required - setting up');
// call mfa setup
navigate('/mfa-setup');
return;
}
await Promise.all([
useServerApiState.getState().fetchServerApiState(),
useUserSettingsState.getState().fetchSettings(),
useGlobalSettingsState.getState().fetchSettings(),
useGlobalStatusState.getState().fetchStatus(),
useIconState.getState().fetchIcons()