From 0ae449515a98eaf28130312da32ef1f1602c6405 Mon Sep 17 00:00:00 2001 From: undefined Date: Thu, 6 Nov 2025 21:40:59 +0800 Subject: [PATCH] framework: allow empty file upload --- framework/framework/api.ts | 6 +++--- framework/framework/package.json | 4 ++-- framework/framework/server.ts | 2 ++ 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/framework/framework/api.ts b/framework/framework/api.ts index a7086f8ed..7da2e5f36 100644 --- a/framework/framework/api.ts +++ b/framework/framework/api.ts @@ -190,7 +190,7 @@ export class ApiHandler extends Handler { if (!['get', 'post'].includes(this.request.method.toLowerCase())) { throw new MethodNotAllowedError(this.request.method); } - if (!APIS[op]) throw new BadRequestError('Invalid operation'); + if (!APIS[op]) throw new BadRequestError(`Invalid API operation: ${op}`); if (APIS[op].type === 'Subscription') { throw new BadRequestError('Subscription operation cannot be called in HTTP handler'); } @@ -226,7 +226,7 @@ export class ApiConnectionHandler extends ConnectionHandler extends ConnectionHandler