Fix cancel auto merge bug (#36341)

This commit is contained in:
Lunny Xiao
2026-01-12 13:47:06 -08:00
committed by GitHub
parent b1b5897795
commit c8b5a1ddf7
3 changed files with 50 additions and 1 deletions
+1 -1
View File
@@ -1322,7 +1322,7 @@ func CancelScheduledAutoMerge(ctx *context.APIContext) {
}
if ctx.Doer.ID != autoMerge.DoerID {
allowed, err := access_model.IsUserRepoAdmin(ctx, ctx.Repo.Repository, ctx.Doer)
allowed, err := pull_service.IsUserAllowedToMerge(ctx, pull, ctx.Repo.Permission, ctx.Doer)
if err != nil {
ctx.APIErrorInternal(err)
return