15 lines
342 B
C#
15 lines
342 B
C#
using FastEndpoints;
|
|
using FluentValidation;
|
|
using Knots.DTO.Key;
|
|
|
|
namespace Knots.Validators.Key;
|
|
|
|
public class CreateKeyDtoValidator : Validator<CreateKeyDto>
|
|
{
|
|
public CreateKeyDtoValidator()
|
|
{
|
|
RuleFor(x => x.EnKey)
|
|
.NotEmpty()
|
|
.WithMessage("La clé de chiffrement ne doit pas être nulle.");
|
|
}
|
|
} |