fix login error

This commit is contained in:
Matthias Hochmeister
2026-02-28 17:35:57 +01:00
parent e2be29c712
commit 4476ca82de
4 changed files with 43 additions and 6 deletions

View File

@@ -91,7 +91,12 @@ export const AuthProvider: React.FC<AuthProviderProps> = ({ children }) => {
});
// Show error notification
notification.showError('Anmeldung fehlgeschlagen. Bitte versuchen Sie es erneut.');
const is429 = error && typeof error === 'object' && 'status' in error && (error as any).status === 429;
notification.showError(
is429
? 'Zu viele Anmeldeversuche. Bitte warten Sie einige Minuten und versuchen Sie es erneut.'
: 'Anmeldung fehlgeschlagen. Bitte versuchen Sie es erneut.'
);
throw error;
}
}, [notification]);