Kavita/Kavita.Models/DTOs/Account/ResetPasswordDto.cs
Fesaa c62b20f54b
BE Tech Debt (#4497)
Co-authored-by: Joseph Milazzo <joseph.v.milazzo@gmail.com>
Co-authored-by: Joe Milazzo <josephmajora@gmail.com>
2026-03-07 10:04:08 -08:00

23 lines
651 B
C#

using System.ComponentModel.DataAnnotations;
namespace Kavita.Models.DTOs.Account;
public sealed record ResetPasswordDto
{
/// <summary>
/// The Username of the User
/// </summary>
[Required]
public string UserName { get; init; } = default!;
/// <summary>
/// The new password
/// </summary>
[Required]
[StringLength(256, MinimumLength = 6)]
public string Password { get; init; } = default!;
/// <summary>
/// The old, existing password. If an admin is performing the change, this is not required. Otherwise, it is.
/// </summary>
public string OldPassword { get; init; } = default!;
}