1
0
Fork 0
mirror of https://codeberg.org/forgejo/forgejo.git synced 2025-10-05 19:30:58 +00:00

[v12.0/forgejo] fix: redirect from /{username}/{reponame}/pulls/{index} to issue if index is a issue (#8876)

**Backport:** !8874

conflict resolved by accepting the incomming hunk and removing TestIssueTimelineLabels-func

Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/8876
Reviewed-by: Earl Warren <earl-warren@noreply.codeberg.org>
Reviewed-by: floss4good <floss4good@noreply.codeberg.org>
Co-authored-by: zokki <zokki.softwareschmiede@gmail.com>
Co-committed-by: zokki <zokki.softwareschmiede@gmail.com>
This commit is contained in:
zokki 2025-08-17 12:18:09 +02:00 committed by Earl Warren
parent 2941adfd11
commit 100ddf45a7
2 changed files with 33 additions and 1 deletions

View file

@ -360,7 +360,7 @@ func getPullInfo(ctx *context.Context) (issue *issues_model.Issue, ok bool) {
ctx.Data["Issue"] = issue
if !issue.IsPull {
ctx.NotFound("ViewPullCommits", nil)
ctx.Redirect(issue.Link())
return nil, false
}