Allow full-size emblems and preserve safe web release retention

This commit is contained in:
unimatrix 2026-11-18 02:08:53 +00:00
commit d28edebb91

View file

@ -1,6 +1,8 @@
export function panelBodyLimit(method,path){
if(method!=='POST')return 65536;
if(path==='/api/internal-mail/messages/send')return 32*1024*1024;
// Emblem endpoints enforce their own raster validation and 2 MB image cap.
if(/^\/api\/(?:clan|company)-emblems\/[a-f0-9]{8}(?:-[a-f0-9]{4}){3}-[a-f0-9]{12}$/i.test(path))return 2*1024*1024;
if(path==='/api/ban-evidence')return 7*1024*1024;
// A validated 2 MB image plus bounded multipart headers.
if(path==='/api/account/avatar')return 2*1024*1024+65536;