Enhance Authentication and Feature Usage Handling
Deploy Development / deploy (push) Successful in 43s
Test Suite / pytest-backend (push) Successful in 42s
Test Suite / lint-backend (push) Successful in 0s
Test Suite / build-frontend (push) Successful in 14s
Test Suite / k6 /health Baseline (push) Successful in 34s
Test Suite / playwright-tests (push) Failing after 1m15s

- Refactored the logout function in AuthContext to handle asynchronous logout operations, improving session management.
- Updated the FeatureUsageBadge component to display error messages when feature data retrieval fails, enhancing user feedback.
- Replaced lazy loading of OnboardingPage with lazyWithRetry for improved loading reliability.
- Adjusted the EntitlementsContext to determine club ID using utility functions for better governance form handling.
This commit is contained in:
Lars committed 2026-06-07 07:05:02 +02:00
1 parent 91dae7b614
commit 8718cf5c70
5 files changed
+55 -11

No files matched your search

+7 -7
View File
@@ -1,4 +1,6 @@
import React, { Suspense, lazy } from 'react'
import LoginPage from './pages/LoginPage'
import { lazyWithRetry } from './utils/lazyWithRetry'
import {
RouterProvider,
createBrowserRouter,
@@ -21,8 +23,7 @@ import ActiveClubSwitcher from './components/ActiveClubSwitcher'
import InactiveMembershipBanner from './components/InactiveMembershipBanner'
import './app.css'
const LoginPage = lazy(() => import('./pages/LoginPage'))
const OnboardingPage = lazy(() => import('./pages/OnboardingPage'))
const OnboardingPage = lazyWithRetry(() => import('./pages/OnboardingPage'))
const VerifyPage = lazy(() => import('./pages/VerifyPage'))
const Dashboard = lazy(() => import('./pages/Dashboard'))
const AccountSettingsPage = lazy(() => import('./pages/AccountSettingsPage'))
@@ -125,11 +126,10 @@ function Nav({ showAdminNav, onboardingOnly }) {
function ProtectedLayout() {
const { isAuthenticated, loading, user, logout } = useAuth()
const handleLogout = () => {
if (confirm('Wirklich abmelden?')) {
logout()
window.location.href = '/'
}
const handleLogout = async () => {
if (!confirm('Wirklich abmelden?')) return
await logout()
window.location.href = '/login'
}
if (loading) {