Skip to content

Commit

Permalink
fix: send 400, don't throw.
Browse files Browse the repository at this point in the history
  • Loading branch information
revam committed Oct 6, 2023
1 parent 1aed66c commit 0aa2ab9
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Shoko.Server/API/v3/Models/Shoko/Group.cs
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,7 @@ public CreateOrUpdateGroupBody(SVR_AnimeGroup group)
var unknownSeriesIDs = SeriesIDs
.Where(id => !seriesList.Any(series => series.AnimeSeriesID == id))
.ToList();
throw new Exception($"Unable to get series with ids \"{string.Join("\", \"", unknownSeriesIDs)}\".");
modelState.AddModelError(nameof(SeriesIDs), $"Unable to get series with ids \"{string.Join("\", \"", unknownSeriesIDs)}\".");
}

// Get a list of all the series across the new inputs and the existing group.
Expand Down

0 comments on commit 0aa2ab9

Please sign in to comment.