mirror of
https://github.com/go-gitea/gitea.git
synced 2026-08-25 18:51:55 +00:00
3af1ee88a5
Backport #39075 by @4RH1T3CT0R7 The "New Pull Request" buttons and the `/pulls/new/{branch}` redirect build their compare link as `{owner}:{branch}`. If a fork and its parent share an owner, through ALLOW_FORK_INTO_SAME_OWNER, or after a transfer, that head resolves back to the base repo, so the link compares the base against itself and 404s on a branch that only exists in the fork. Switching to `{owner}/{repo}:{branch}` names the head repo unambiguously, and it's what the compare page's own links already use. Also clears the 404 in #37649; the archived-parent half of that report is separate. Co-authored-by: Artem Lytkin <146867384+4RH1T3CT0R7@users.noreply.github.com>