Skip to content

Commit f9562d5

Browse files
committed
fix: 执行请求时this上下文指向错误
1 parent 4688f79 commit f9562d5

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/generate-template.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ var ${className} = class extends BaseOpenapiClient {
215215
return metas[method]
216216
.filter((meta) => meta.tags.includes(ns))
217217
.map((meta) => {
218-
return `${camelCase(meta.key)}(opts) {
218+
return `${camelCase(meta.key)}: (opts) => {
219219
return this.request('${meta.uri}', '${method}', opts);
220220
},`;
221221
});

0 commit comments

Comments
 (0)