Skip to content

Commit

Permalink
fix: 执行请求时this上下文指向错误
Browse files Browse the repository at this point in the history
  • Loading branch information
geekact committed Jul 20, 2024
1 parent 76692e7 commit 49c9196
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/generate-template.ts
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ var ${className} = class extends BaseOpenapiClient {
return metas[method]
.filter((meta) => meta.tags.includes(ns))
.map((meta) => {
return `${camelCase(meta.key)}(opts) {
return `${camelCase(meta.key)}: (opts) => {
return this.request('${meta.uri}', '${method}', opts);
},`;
});
Expand Down

0 comments on commit 49c9196

Please sign in to comment.