@using Data_Coupler.Services @using Data_Coupler.Pages @inject IAuthenticationService AuthService @implements IDisposable @if (!AuthService.IsAuthenticated) { } else { @{ // Se l'utente prova ad accedere alla pagina di login mentre è autenticato, reindirizza alla home if (routeData.PageType == typeof(Data_Coupler.Pages.Login)) { } else { } } Not found

Sorry, there's nothing at this address.

} @code { protected override void OnInitialized() { AuthService.OnAuthenticationStateChanged += OnAuthenticationStateChanged; } public void Dispose() { AuthService.OnAuthenticationStateChanged -= OnAuthenticationStateChanged; } private void OnAuthenticationStateChanged() { InvokeAsync(StateHasChanged); } private RouteData CreateHomeRouteData() { return new RouteData(typeof(Data_Coupler.Pages.DataCoupler), new Dictionary()); } }