mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2025-05-17 07:22:42 +00:00
Fix incorrect redirection when creating a PR fails (#29537)
This is only a quick fix to make it easier to backport.
After this PR gets merged, I will propose a new PR to fix the FIXME.
<details>

</details>
(cherry picked from commit e650f64d812f5ebeb4a11d2ec20f2376c6d963bc)
This commit is contained in:
parent
5241a45cf8
commit
db19d4eb39
5 changed files with 6 additions and 24 deletions
|
@ -1535,7 +1535,7 @@ func CompareAndPullRequestPost(ctx *context.Context) {
|
|||
return
|
||||
}
|
||||
ctx.Flash.Error(flashError)
|
||||
ctx.JSONRedirect(pullIssue.Link()) // FIXME: it's unfriendly, and will make the content lost
|
||||
ctx.JSONRedirect(ctx.Link + "?" + ctx.Req.URL.RawQuery) // FIXME: it's unfriendly, and will make the content lost
|
||||
return
|
||||
}
|
||||
ctx.ServerError("NewPullRequest", err)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue