diff --git a/deno.json b/deno.json index 125f55b..26b1c3d 100644 --- a/deno.json +++ b/deno.json @@ -1,11 +1,11 @@ { "name": "@loongwoo/stc", - "version": "1.6.2", + "version": "1.6.3", "exports": "./mod.ts", "tasks": { "dev": "deno run -A --watch=src src/main.ts --url 'https://petstore3.swagger.io/api/v3/openapi.json'", "serve": "deno run -A --watch=src src/service.ts", - "version": "echo '1.6.2' > release/version", + "version": "echo '1.6.3' > release/version", "build:npm": "deno run -A src/npm/index.ts", "build:mac": "deno compile -A --target x86_64-apple-darwin --output release/stc src/main.ts", "build:mac-m": "deno compile -A --target aarch64-apple-darwin --output release/stc-m src/main.ts", diff --git a/src/npm/pkg.json b/src/npm/pkg.json index c8cbb5e..593504f 100644 --- a/src/npm/pkg.json +++ b/src/npm/pkg.json @@ -1,6 +1,6 @@ { "name": "@loongwoo/stc", - "version": "1.6.2", + "version": "1.6.3", "description": "OpenApi/Swagger/Apifox document conversion tool.\nOpenAPI(Swagger)、Apifox 文档转换为接口文件。", "type": "module", "module": "esm/mod.js", diff --git a/src/path.ts b/src/path.ts index d7de13a..b10c6a0 100644 --- a/src/path.ts +++ b/src/path.ts @@ -263,7 +263,7 @@ export const getApiPath = ( // 添加请求方式标识,如 GET,POST 等,防止重名。设置了 operationId,以 operationId 为准 if ( !currentMethod.operationId && - !/^(get|post|put|delete|options|head|patch)$/i.test( + !/^(get|post|put|delete|options|head|patch)/i.test( name.slice(0, method.length), ) ) {