1
0

nullReference

This commit is contained in:
glax 2024-02-22 05:54:41 +01:00
parent b1a3d2685c
commit 7478741ba2

View File

@ -22,7 +22,7 @@ else
throw new ArgumentNullException(nameof(discordKey));
int imageKeyIndex = Array.IndexOf(args, "-i");
string? imageKey = null;
string imageKey = "cat";
if(imageKeyIndex > -1)
if (imageKeyIndex + 1 < args.Length)
imageKey = args[imageKeyIndex + 1];