adds albumid and makes properties init only, also suppresses some warnings

This commit is contained in:
Philipp Häfelfinger 2022-11-19 10:02:35 +01:00
parent 343fc29238
commit 074da8a4d8
1 changed files with 5 additions and 1 deletions

View File

@ -5,8 +5,12 @@ namespace Piwigo.Client.Cli;
[Verb("upload", HelpText = "Add file contents to the index.")]
[SuppressMessage("ReSharper", "ClassNeverInstantiated.Global", Justification = "done by command line parser")]
[SuppressMessage("ReSharper", "AutoPropertyCanBeMadeGetOnly.Global", Justification = "used by command line parser")]
internal class UploadOptions : BaseOptions
{
[Option('i', "image", Required = true, HelpText = "Path to the image to upload")]
public string ImagePath { get; set; } = null!;
public string ImagePath { get; init; } = null!;
[Option('a', "albumId", Required = false, HelpText = "The album id where the picture belongs")]
public int? AlbumId { get; init; } = null;
}