mirror of
https://github.com/EKKOLearnAI/hermes-web-ui.git
synced 2026-06-05 02:30:19 +00:00
12e0b5ebed
Profile avatars are sent to /profiles/:name/avatar as base64 image data URLs in a JSON body. The handler allows up to 1MB of raw image data, which is ~1.37MB once base64-encoded — larger than @koa/bodyparser's default 1mb jsonLimit, so uploads were rejected with HTTP 413 before reaching the handler. Set jsonLimit/textLimit to 4mb, leaving the handler's own 1MB raw-size check as the authoritative limit (now returning a clear 400 instead of a confusing 413). Co-authored-by: xingzhi <chuzihao.czh@alibaba-inc.com>