Skip to content

Commit 6d0dc1e

Browse files
authored
Merge branch 'main' into revert-aria-role
2 parents 94fe4f0 + 1af3dc6 commit 6d0dc1e

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

routers/web/repo/compare.go

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -551,7 +551,11 @@ func ParseCompareInfo(ctx *context.Context) *CompareInfo {
551551
ctx.ServerError("GetCompareInfo", err)
552552
return nil
553553
}
554-
ctx.Data["BeforeCommitID"] = ci.CompareInfo.MergeBase
554+
if ci.DirectComparison {
555+
ctx.Data["BeforeCommitID"] = ci.CompareInfo.BaseCommitID
556+
} else {
557+
ctx.Data["BeforeCommitID"] = ci.CompareInfo.MergeBase
558+
}
555559

556560
return ci
557561
}

0 commit comments

Comments
 (0)