publicstaticPKErrorExistingSystemError=>newPKError("You already have a system registered with PluralKit. To view it, type `pk;system`. If you'd like to delete your system and start anew, type `pk;system delete`, or if you'd like to unlink this account from it, type `pk;unlink`.");
publicstaticPKErrorInvalidColorError(stringcolor)=>newPKError($"\"{color}\" is not a valid color. Color must be in hex format (eg. #ff0000).");
publicstaticPKErrorBirthdayParseError(stringbirthday)=>newPKError($"\"{birthday}\" could not be parsed as a valid date. Try a format like \"2016-12-24\" or \"May 3 1996\".");
publicstaticPKErrorAvatarServerError(HttpStatusCodestatusCode)=>newPKError($"Server responded with status code {(int) statusCode}, are you sure your link is working?");
publicstaticPKErrorAvatarFileSizeLimit(longsize)=>newPKError($"File size too large ({size.Bytes().ToString("#.#")} > {Limits.AvatarFileSizeLimit.Bytes().ToString("#.#")}), try shrinking or compressing the image.");
publicstaticPKErrorAvatarNotAnImage(stringmimeType)=>newPKError($"The given link does not point to an image{(mimeType != null ? $"({mimeType})" : "")}. Make sure you're using a direct link (ending in .jpg, .png, .gif).");
publicstaticPKErrorAvatarDimensionsTooLarge(intwidth,intheight)=>newPKError($"Image too large ({width}x{height} > {Limits.AvatarDimensionLimit}x{Limits.AvatarDimensionLimit}), try resizing the image.");
publicstaticPKErrorInvalidUrl(stringurl)=>newPKError($"The given URL is invalid.");
publicstaticPKErrorAccountAlreadyLinked=>newPKError("That account is already linked to your system.");
publicstaticPKErrorAccountNotLinked=>newPKError("That account isn't linked to your system.");
publicstaticPKErrorAccountInOtherSystem(PKSystemsystem)=>newPKError($"The mentioned account is already linked to another system (see `pk;system {system.Hid}`).");
publicstaticPKErrorUnlinkingLastAccount=>newPKError("Since this is the only account linked to this system, you cannot unlink it (as that would leave your system account-less).");
publicstaticPKErrorMemberLinkCancelled=>newPKError("Member link cancelled.");
if(members.Count==0)returnnewPKError("There's already no one in front.");
if(members.Count==1)returnnewPKError($"Member {members.First().Name} is already fronting.");
returnnewPKError($"Members {string.Join(",", members.Select(m => m.Name))} are already fronting.");
}
publicstaticPKErrorDuplicateSwitchMembers=>newPKError("Duplicate members in member list.");
publicstaticPKErrorInvalidDateTime(stringstr)=>newPKError($"Could not parse '{str}' as a valid date/time.");
publicstaticPKErrorSwitchTimeInFuture=>newPKError("Can't move switch to a time in the future.");
publicstaticPKErrorNoRegisteredSwitches=>newPKError("There are no registered switches for this system.");
publicstaticPKErrorSwitchMoveBeforeSecondLast(ZonedDateTimetime)=>newPKError($"Can't move switch to before last switch time ({time.ToString(Formats.DateTimeFormat, null)}), as it would cause conflicts.");