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

Already read Error #1792

Closed
michaeltomasik opened this issue Apr 24, 2017 · 5 comments
Closed

Already read Error #1792

michaeltomasik opened this issue Apr 24, 2017 · 5 comments

Comments

@michaeltomasik
Copy link

michaeltomasik commented Apr 24, 2017

Hello, i have problem with routing. When i'm redirecting via

Router.push({ pathname:`/overview.html`, query: { id } }, `/${id}/overview.html`)
(file is named overview.html.js)

I'm getting "Already Read"

  server.get('/:id/*', (req, res) => {
    const path = req.path.replace(`/${req.params.id}`, '')
    app.render(req, res, path, req.params)
  })

image
image

But when I reload page with given url, it will work

@lfades
Copy link
Member

lfades commented Apr 24, 2017

I can confirm that I have the same problem but when I redirect several times very fast with Router.push().
+1

@AugustinLF
Copy link
Contributor

It also happens if you click several times on a <Link/> while the server is building the corresponding page.

@arunoda
Copy link
Contributor

arunoda commented Apr 25, 2017

Could you update Next to the latest 2.2.0, we've fixed this issue. (Actually replaced the logic of the source of this issue)?

Let me if it's still the same.

@supernintendo
Copy link

supernintendo commented Apr 25, 2017

@arunoda FWIW, upgrading to 2.2.0 fixed this bug for me. It would be nice to maybe add a console.warn (or maybe some visual indication only in non-production environments) indicating that the page for a link is still loading upon click; the current implementation is a bit jarring.

@michaeltomasik
Copy link
Author

michaeltomasik commented Apr 25, 2017

@arunoda I upgraded it to 2.2.0 , and it worked , thanks :)

@lock lock bot locked as resolved and limited conversation to collaborators May 11, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants