feat: Eigenschaften zu LogInDto für Validierung und Null-Prüfungen hinzugefügt
This commit is contained in:
@@ -1,4 +1,9 @@
|
||||
namespace WorkFlow.API.Models
|
||||
{
|
||||
public record LogInDto(int? UserId, string? Username, string Password);
|
||||
public record LogInDto(int? UserId, string? Username, string Password)
|
||||
{
|
||||
public bool HasUserId => UserId is not null;
|
||||
public bool HasUsername => Username is not null;
|
||||
public bool IsInvalid => !HasUserId && !HasUsername;
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user