Skip to content
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

Axios 0.25.0 put request ignores 0 and false as a request payload #4440

Closed
levaleks opened this issue Feb 1, 2022 · 0 comments
Closed

Axios 0.25.0 put request ignores 0 and false as a request payload #4440

levaleks opened this issue Feb 1, 2022 · 0 comments

Comments

@levaleks
Copy link

levaleks commented Feb 1, 2022

Describe the bug

Hi! I'm having a similar issue reported for post requests here #3549

To Reproduce

Code snippet to reproduce

axios
  .put(url, 0, { headers: { 'Content-Type': 'application/octet-stream' } })
  .then(() => { ... })
  .catch(() => { ... });

OR

axios
  .put(url, false, { headers: { 'Content-Type': 'application/octet-stream' } })
  .then(() => { ... })
  .catch(() => { ... });

Expected behavior

These values should not be ignored.

Environment

  • Axios Version 0.25.0
  • Browser Chrome
  • Browser Version Chrome - Version 97.0.4692.99 (Official Build) (arm64)
  • OS: OSX 12.1

Additional context/Screenshots

Nothing here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants