hanyadikhetvan-dotnethf/HanyadikHetVan/Areas/Identity/Pages/Account/Manage/ShowRecoveryCodes.cshtml.cs
Torma Kristóf 634488c2d8
All checks were successful
continuous-integration/drone/push Build is passing
addfunfacts
2021-05-19 17:56:56 +02:00

32 lines
805 B
C#

using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading.Tasks;
using HanyadikHetVan.Data.Entities;
using Microsoft.AspNetCore.Identity;
using Microsoft.AspNetCore.Mvc;
using Microsoft.AspNetCore.Mvc.RazorPages;
using Microsoft.Extensions.Logging;
namespace HanyadikHetVan.Areas.Identity.Pages.Account.Manage
{
public class ShowRecoveryCodesModel : PageModel
{
[TempData]
public string[] RecoveryCodes { get; set; }
[TempData]
public string StatusMessage { get; set; }
public IActionResult OnGet()
{
if (RecoveryCodes == null || RecoveryCodes.Length == 0)
{
return RedirectToPage("./TwoFactorAuthentication");
}
return Page();
}
}
}