21 lines
514 B
Plaintext
21 lines
514 B
Plaintext
@page "/CreateServer"
|
|
@using Microsoft.AspNetCore.Http
|
|
@using Microsoft.AspNetCore.Authentication
|
|
@inject IHttpContextAccessor _httpContextAccessor
|
|
<AuthorizeView>
|
|
<Authorized>
|
|
|
|
</Authorized>
|
|
<NotAuthorized>
|
|
<h1>You must be logged in to view this page!</h1>
|
|
</NotAuthorized>
|
|
</AuthorizeView>
|
|
|
|
@code {
|
|
protected async override Task OnInitializedAsync()
|
|
{
|
|
string token = await _httpContextAccessor.HttpContext.GetTokenAsync("access_token");
|
|
var t = 2;
|
|
}
|
|
|
|
} |