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

Proxy does not send UrlSearchParams or FormData in real request #62

Open
nicholasgonzalezsc opened this issue Apr 20, 2018 · 6 comments

Comments

@nicholasgonzalezsc
Copy link

Bug Description
When making a proxied xhr request with application/x-www-form-urlencoded;charset=utf-8 data, the request body is not passed along to the real request.

Expected Behavior
Proxy passes the form data to the real request.

@nicholasgonzalezsc
Copy link
Author

Hey @jameslnewell, have you had a chance to take a look at this? If you can point me in the right direction, I can help with the change

@jameslnewell
Copy link
Owner

Sorry @nicholasgonzalezsc I'm on holidays. I'll take a look sometime next week. At a guess I'd say its because we're only passing the responseText, not the response here. Feel free to submit a PR 😁

@jameslnewell
Copy link
Owner

jameslnewell commented May 1, 2018

Checkout v2.3.2. It fixes the proxy to return the correct response body.

Let me know if it doesn't fix your issue.

@lk77
Copy link

lk77 commented Apr 5, 2019

Hello,
i still have this issue on v2.4.1,
form data is missing in request.

if i do :

mock.setup()
mock.use(proxy)

There is no form data, and if i comment those lines, there is form data.

it's a multipart form upload (https://upload.filestackapi.com/multipart/start),
perhaps it's the problem here.

thanks.

@jameslnewell
Copy link
Owner

Thanks @lk77. Could you please provide a code sample using a service like CodeSandbox where I can reproduce the issue?

@jameslnewell jameslnewell reopened this Apr 5, 2019
@lk77
Copy link

lk77 commented Apr 9, 2019

Hello,
i will try to do so

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

3 participants