Allow unlimited joker suggestions when granted repeatedly
This commit is contained in:
@@ -78,10 +78,9 @@ public static class SuggestEndpoints
|
||||
}
|
||||
|
||||
var existingCount = await db.Suggestions.CountAsync(s => s.PlayerId == player.Id);
|
||||
var maxSuggestions = usingJoker ? 6 : 5;
|
||||
if (existingCount >= maxSuggestions)
|
||||
if (!usingJoker && existingCount >= 5)
|
||||
{
|
||||
return Results.BadRequest(new { error = "You have reached the suggestion limit." });
|
||||
return Results.BadRequest(new { error = "You have reached the 5 suggestion limit." });
|
||||
}
|
||||
|
||||
var suggestion = new Suggestion
|
||||
|
||||
Reference in New Issue
Block a user