mirror of
https://github.com/bitwarden/server.git
synced 2025-07-01 08:02:49 -05:00
get recovery code api
This commit is contained in:
@ -0,0 +1,21 @@
|
||||
using System;
|
||||
using Bit.Core.Models.Table;
|
||||
|
||||
namespace Bit.Core.Models.Api
|
||||
{
|
||||
public class TwoFactorRecoverResponseModel : ResponseModel
|
||||
{
|
||||
public TwoFactorRecoverResponseModel(User user)
|
||||
: base("twoFactorRecover")
|
||||
{
|
||||
if(user == null)
|
||||
{
|
||||
throw new ArgumentNullException(nameof(user));
|
||||
}
|
||||
|
||||
Code = user.TwoFactorRecoveryCode;
|
||||
}
|
||||
|
||||
public string Code { get; set; }
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user