edge icon indicating copy to clipboard operation
edge copied to clipboard

queryString problem in `proxy` implementation

Open barnese3 opened this issue 6 years ago • 0 comments

Query strings are being ignored in requests.

Example: requests like blah.com/path?stuff are getting sent to backends as just /path

Found with the following code while creating middleware/device-router:

if (deviceType === "mobile" && osName === "Android") {
  const backend = origin({
      origin: `https://play.google.com/store/apps/details?id=${options.android}`,
      headers: {host: "play.google.com"}
  });
  return backend(req);
}

origin is only being seen as https://play.google.com/store/apps/details rather than https://play.google.com/store/apps/details?id=${options.android}

barnese3 avatar Jan 28 '19 19:01 barnese3