Use correct start and end commits for GetDiffTree (#33816)

Fixes
https://github.com/go-gitea/gitea/pull/33514#issuecomment-2702814099

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
Alexander McRaeandwxiaoguang authored and GitHub committed 2025-03-07 02:40:39 +00:00
1 parent ef18655215
commit 582ad338d7
1 file changed
+1 -1
+1 -1
View File
@@ -820,7 +820,7 @@ func viewPullFiles(ctx *context.Context, specifiedStartCommit, specifiedEndCommi
if !fileOnly {
// note: use mergeBase is set to false because we already have the merge base from the pull request info
diffTree, err := gitdiff.GetDiffTree(ctx, gitRepo, false, pull.MergeBase, headCommitID)
diffTree, err := gitdiff.GetDiffTree(ctx, gitRepo, false, startCommitID, endCommitID)
if err != nil {
ctx.ServerError("GetDiffTree", err)
return