-
Notifications
You must be signed in to change notification settings - Fork 118
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: fix undefined search params of get method #436
Conversation
@@ -405,9 +406,10 @@ export class HttpClient extends EventEmitter { | |||
|| isReadable(args.data); | |||
if (isGETOrHEAD) { | |||
if (!isStringOrBufferOrReadable) { | |||
for (const field in args.data) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
只过滤 undefined 吧,其他还是按照 URL SearchParams 默认逻辑来, querystring 模块不是标准的规范。
Codecov Report
@@ Coverage Diff @@
## master #436 +/- ##
=======================================
Coverage 99.67% 99.67%
=======================================
Files 8 8
Lines 1222 1224 +2
Branches 233 233
=======================================
+ Hits 1218 1220 +2
Misses 4 4
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
还是保持 URL SearchParams 的逻辑 |
fix this