diff --git a/package.json b/package.json index 12d84bb..f204c3b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "@elysiajs/swagger", - "version": "1.1.4", + "version": "1.1.5", "description": "Plugin for Elysia to auto-generate Swagger page", "author": { "name": "saltyAom", diff --git a/src/utils.ts b/src/utils.ts index b0a24a6..62c182a 100644 --- a/src/utils.ts +++ b/src/utils.ts @@ -124,6 +124,8 @@ export const registerSchemaPath = ({ hook?: LocalHook models: Record }) => { + hook = cloneHook(hook) + const contentType = hook?.type ?? [ 'application/json', 'multipart/form-data',