diff --git a/bun.lockb b/bun.lockb index 17f1f21..a54eacc 100755 Binary files a/bun.lockb and b/bun.lockb differ diff --git a/package.json b/package.json index 86bef0d..ea5c49c 100644 --- a/package.json +++ b/package.json @@ -35,7 +35,7 @@ "release": "npm run build && npm run test && npm publish --access public" }, "peerDependencies": { - "elysia": ">= 1.0.0-beta.5" + "elysia": ">= 1.0.0-beta.9" }, "devDependencies": { "@apidevtools/swagger-parser": "^10.1.0", @@ -43,7 +43,7 @@ "@types/bun": "^1.0.4", "@types/lodash.clonedeep": "^4.5.7", "@types/node": "^20.1.4", - "elysia": "1.0.0-beta.5", + "elysia": "1.0.0-beta.9", "eslint": "^8.40.0", "rimraf": "4.3", "typescript": "^5.0.4" diff --git a/src/index.ts b/src/index.ts index b137288..b585d7b 100644 --- a/src/index.ts +++ b/src/index.ts @@ -64,7 +64,7 @@ export const swagger = app.get( path, - (() => { + () => { const combinedSwaggerOptions = { url: `${relativePath}/json`, dom_id: '#swagger-ui', @@ -108,11 +108,11 @@ export const swagger = } } ) - })() + } ).get( `${path}/json`, () => { - const routes = app.router.history as InternalRoute[] + const routes = app.routes as InternalRoute[] if (routes.length !== totalRoutes) { totalRoutes = routes.length