Skip to content

Commit

Permalink
Merge pull request #139 from zoto-ff-forks/main
Browse files Browse the repository at this point in the history
  • Loading branch information
SaltyAom authored Sep 27, 2024
2 parents 18860ac + 78aa870 commit cf53c6e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
2 changes: 0 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,12 @@
"@apidevtools/swagger-parser": "^10.1.0",
"@scalar/api-reference": "^1.12.5",
"@types/bun": "1.1.6",
"@types/lodash.clonedeep": "^4.5.9",
"elysia": ">= 1.1.0-rc.2",
"eslint": "9.6.0",
"tsup": "^8.1.0",
"typescript": "^5.5.3"
},
"dependencies": {
"lodash.clonedeep": "^4.5.0",
"openapi-types": "^12.1.3",
"pathe": "^1.1.2"
}
Expand Down
6 changes: 1 addition & 5 deletions src/utils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ import type { HTTPMethod, LocalHook } from 'elysia'
import { Kind, type TSchema } from '@sinclair/typebox'
import type { OpenAPIV3 } from 'openapi-types'

import deepClone from 'lodash.clonedeep'

export const toOpenAPIPath = (path: string) =>
path
.split('/')
Expand Down Expand Up @@ -116,9 +114,7 @@ export const registerSchemaPath = ({
method: HTTPMethod
hook?: LocalHook<any, any, any, any, any, any, any>
models: Record<string, TSchema>
}) => {
if (hook) hook = deepClone(hook)

}) => {
const contentType = hook?.type ?? [
'application/json',
'multipart/form-data',
Expand Down

0 comments on commit cf53c6e

Please sign in to comment.