add header in profile page

This commit is contained in:
2024-10-30 23:28:47 +01:00
Unverified
parent 017b3ac185
commit 2f6eb33518
17 changed files with 213 additions and 31 deletions

View File

@@ -62,6 +62,9 @@ public class AccountsControllerService(
RefreshToken = await refreshTokenTask,
};
account.LastActive = DateTime.UtcNow;
await database.SaveChangesAsync();
logger.LogInformation($"Account with ID {account.Id} was authenticated");
return RequestResult.Ok(response);
}
@@ -91,6 +94,9 @@ public class AccountsControllerService(
string accessToken = await tokensService.CreateAccessTokenAsync(token.Account);
token.Account.LastActive = DateTime.UtcNow;
await database.SaveChangesAsync();
logger.LogInformation($"Account with ID {token.AccountId} was authenticated by token refreshing");
return RequestResult.Ok(new AuthenticateResponse
{