Login loses hash from link

Summary

Opening a link like: https://host/owner/repo/path/to/file#L345-347 loses the hash after the log-in wall is hit.

Steps to reproduce

  1. Go to a (private) repo and copy a link to a specific line or line range
  2. Log out
  3. Open copied link
  4. (Log in screen hit)
  5. Log in
  6. Redirected to file

What is the current bug behavior?

path/to/file focused on top, because hash is lost

What is the expected correct behavior?

path/to/file focused on specified lines

Output of checks

I think we have a private GitLab server, GitLab Community Edition 11.0.2 gitlab-ce@d9540ee0464796746ec0906c0c2762ca099be3e5

Edited Aug 02, 2025 by 🤖 GitLab Bot 🤖
Assignee Loading
Time tracking Loading