Correct bunch of issues (#36)
All checks were successful
Game Ideas deploy / build-test-deploy (push) Successful in 1m28s

Reviewed-on: #36
This commit was merged in pull request #36.
This commit is contained in:
2025-04-29 23:49:11 +02:00
parent d3d16493e6
commit f3c9e1d9da
37 changed files with 246 additions and 186 deletions

View File

@@ -14,8 +14,10 @@ public class AuthGateway(IHttpClientService httpClient,
{
try
{
var token = await httpClient.PostAsync<TokenDto>(Endpoints.Auth.Login, userDto);
await ((JwtAuthenticationStateProvider)stateProvider).NotifyUserAuthenticationAsync(token!.Token!);
var token = await httpClient.PostAsync<TokenDto>(Endpoints.Auth.Login, userDto)
?? throw new InvalidOperationException("Could not retrieve token");
await ((JwtAuthenticationStateProvider)stateProvider).NotifyUserAuthenticationAsync(token);
return true;
}
catch (Exception)

View File

@@ -14,7 +14,7 @@ public partial class UserMenu
{
ContentVisile = false;
await AuthGateway.Logout();
NavigationManager.NavigateTo("/Games");
NavigationManager.NavigateTo("/");
}
private void HandleAccountClicked()