Artiom Fotescu
3 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
src/Web/Controllers/UserController.cs
|
|
|
@ -24,7 +24,7 @@ public class UserController : ControllerBase |
|
|
|
[Authorize] |
|
|
|
[AllowAnonymous] |
|
|
|
public async Task<IActionResult> GetCurrentUser() => |
|
|
|
Ok(User.Identity.IsAuthenticated ? await CreateUserInfo(User) : UserInfo.Anonymous); |
|
|
|
Ok(await CreateUserInfo(User)); |
|
|
|
|
|
|
|
private async Task<UserInfo> CreateUserInfo(ClaimsPrincipal claimsPrincipal) |
|
|
|
{ |
|
|
|
|