Skip to content

Commit

Permalink
fix ts request cli (#4461)
Browse files Browse the repository at this point in the history
Co-authored-by: robinzhang <azhangrongbing@163.com>
  • Loading branch information
metaRobin and robinzhang authored Nov 21, 2024
1 parent 7c8f41d commit cad2439
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tools/goctl/api/tsgen/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export function parseParams(url: string): Array<string> {
* @param url
* @param params
*/
export function genUrl(url: string, params: unknown) {
export function genUrl(url: string, params: any) {
if (!params) {
return url;
}
Expand Down Expand Up @@ -113,7 +113,7 @@ export const webapi = {
return api<T>('delete', url, req, config);
},
put<T>(url: string, req: unknown, config?: unknown): Promise<T> {
return api<T>('get', url, req, config);
return api<T>('put', url, req, config);
},
post<T>(url: string, req: unknown, config?: unknown): Promise<T> {
return api<T>('post', url, req, config);
Expand Down

0 comments on commit cad2439

Please sign in to comment.