Skip to content

Commit

Permalink
fix(script): 修复请求模块的重大BUG
Browse files Browse the repository at this point in the history
  • Loading branch information
enncy committed Dec 11, 2023
1 parent fc34069 commit 4b121bb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/core/src/core/utils/request.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ export function request<T extends 'json' | 'text'>(
const requestData =
contentType === 'application/x-www-form-urlencoded'
? new URLSearchParams(data).toString()
: Object.keys(headers).length
: Object.keys(data).length
? JSON.stringify(data)
: undefined;
// eslint-disable-next-line no-undef
Expand Down

0 comments on commit 4b121bb

Please sign in to comment.