Skip to content

Commit

Permalink
Fix error message for 1 error
Browse files Browse the repository at this point in the history
  • Loading branch information
cooolbros committed Feb 15, 2024
1 parent cffa278 commit 41a637f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/HUDMerger/Models/HUD.cs
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,7 @@ public static void Merge(HUD source, HUD target, HUDPanel[] panels)
if (exceptions.Count != 0)
{
throw new Exception(string.Join("\r\n", [
$"{exceptions.Count} error{(exceptions.Count != 1 ? "s" : "")} were encountered while trying to merge:",
$"{exceptions.Count} error{(exceptions.Count != 1 ? "s" : "")} {(exceptions.Count != 1 ? "were" : "was")} encountered while trying to merge:",
"",
..exceptions
.OrderBy((e) => e is FileException fileException ? (fileException.HUD == source ? 0 : 1) : 0)
Expand Down

0 comments on commit 41a637f

Please sign in to comment.