Cleanup of lazy loading code. Made some DTOs use init rather than set to keep it clean.

This commit is contained in:
Joseph Milazzo 2021-03-12 13:20:08 -06:00
parent 33515ad865
commit af35d8aad5
18 changed files with 103 additions and 68 deletions

View file

@ -7,11 +7,11 @@ namespace API.DTOs
public class CreateLibraryDto
{
[Required]
public string Name { get; set; }
public string Name { get; init; }
[Required]
public LibraryType Type { get; set; }
public LibraryType Type { get; init; }
[Required]
[MinLength(1)]
public IEnumerable<string> Folders { get; set; }
public IEnumerable<string> Folders { get; init; }
}
}