Skip to content

Commit b767182

Browse files
authored
Allow empty assignees on pull request edit (#22150)
Fixes #22140
1 parent 48d71b7 commit b767182

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

routers/api/v1/repo/pull.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -490,6 +490,11 @@ func EditPullRequest(ctx *context.APIContext) {
490490
issue := pr.Issue
491491
issue.Repo = ctx.Repo.Repository
492492

493+
if err := issue.LoadAttributes(ctx); err != nil {
494+
ctx.Error(http.StatusInternalServerError, "LoadAttributes", err)
495+
return
496+
}
497+
493498
if !issue.IsPoster(ctx.Doer.ID) && !ctx.Repo.CanWrite(unit.TypePullRequests) {
494499
ctx.Status(http.StatusForbidden)
495500
return

0 commit comments

Comments
 (0)