Bump description max length to 512, log character count

This commit is contained in:
jvyden 2022-07-25 19:24:18 -04:00
parent 23900f8217
commit 5d6e339fa8
No known key found for this signature in database
GPG key ID: 18BCF2BE0262B278

View file

@ -95,15 +95,15 @@ public class PublishController : ControllerBase
return this.BadRequest();
}
if (slot.Description.Length > 500)
if (slot.Description.Length > 512)
{
Logger.Warn("Rejecting level upload, description too long", LogArea.Publish);
Logger.Warn($"Rejecting level upload, description too long ({slot.Description.Length} characters)", LogArea.Publish);
return this.BadRequest();
}
if (slot.Name.Length > 64)
{
Logger.Warn("Rejecting level upload, title too long", LogArea.Publish);
Logger.Warn($"Rejecting level upload, title too long ({slot.Name.Length} characters)", LogArea.Publish);
return this.BadRequest();
}