Going back to previous internal page after 404

Steps to get this bug:

  1. You click on a link which redirects to a section where you don’t have access to.
  2. If it says error 404, click on the < button to go to the previous page
  3. It just redirects to the 404 page instead of the previous page.

No repro.

  1. Open new Chrome incognito window
  2. Navigate to google.com
  3. I try to visit the URL of a staff topic on try.discourse.org and get a 404
  4. Press back button, I am taken back to Google
2 Likes

It happens to me when I do this:
55%20AM
In discourse, I click on the link above, but I don’t have permissions to go to the that site setting.
Then I can’t go back to the discourse post with the link.

Use the browser menu on the back link. Click and hold, or tap and hold, on the back arrow:

image

1 Like

I’m fairly sure that this has to do with our click interceptor failing to avoid stepping on ember route’s toes - I fixed a similar issue we noticed while navigating to the hidden profile pages, and it sounds like that it’s the same issue you’re experiencing here :fallen_leaf:

10 Likes

FYI this wasn’t it and these changes have been reverted - I’ll be looking for a better solution to this soon.

5 Likes

Was this change merged in? I’ve got a relatively recent version running and am running into the same problem where you can’t use the back button on the browser from a hidden profile page. I was able to reproduce it here on meta, also.

2 Likes

@maja can you have a look?

5 Likes

Can repro this by going to the regular badge page.
https://meta.discourse.org/badges/3/regular
then viewing this fella’s profile there


then trying to go back to the previous internal page.

Robin made a patch here that may resolve this. I’m no longer able to reproduce the issue reported here on meta since the patch, @Chaboi_3000 can you confirm this?

4 Likes

Yep, it’s fixed now. Thanks.

4 Likes