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

Query part of URL is not preserved across redirects #57

Open
17320 opened this issue Oct 5, 2018 · 0 comments · May be fixed by #58
Open

Query part of URL is not preserved across redirects #57

17320 opened this issue Oct 5, 2018 · 0 comments · May be fixed by #58

Comments

@17320
Copy link

17320 commented Oct 5, 2018

When serving a request for /some/path where the actual resource is /some/path/index.html, the server performs an HTTP 302 redirect to /some/path/, but in the process, it loses any query information the original URL might have had.

Recall that query parts may be used not just by the server but also by client-side Javascript.

Test case

  1. Have a resource such as /some/path/index.html
  2. Start hexo-server
  3. Request /some/path?id=test

Expected result

The user is redirected to /some/path/?id=test (assuming root is /).

Actual result

The user is redirected to /some/path/ and the query information is lost.

@17320 17320 linked a pull request Oct 5, 2018 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant