@@ -272,7 +272,7 @@ func editFilePost(ctx *context.Context, form forms.EditRepoFileForm, isNewFile b
272272 renderCommitRights (ctx , editRepo )
273273
274274 // Cannot commit to an existing branch if user doesn't have rights
275- if ! canPushToEditRepository (ctx , editRepo , branchName , tplEditFile , & form ) {
275+ if ! canPushToEditRepository (ctx , editRepo , branchName , form . CommitChoice , tplEditFile , & form ) {
276276 return
277277 }
278278
@@ -512,7 +512,7 @@ func DeleteFilePost(ctx *context.Context) {
512512 renderCommitRights (ctx , editRepo )
513513
514514 // Cannot commit to an existing branch if user doesn't have rights
515- if ! canPushToEditRepository (ctx , editRepo , branchName , tplDeleteFile , & form ) {
515+ if ! canPushToEditRepository (ctx , editRepo , branchName , form . CommitChoice , tplDeleteFile , & form ) {
516516 return
517517 }
518518
@@ -710,7 +710,7 @@ func UploadFilePost(ctx *context.Context) {
710710
711711 renderCommitRights (ctx , editRepo )
712712
713- if ! canPushToEditRepository (ctx , editRepo , branchName , tplUploadFile , & form ) {
713+ if ! canPushToEditRepository (ctx , editRepo , branchName , form . CommitChoice , tplUploadFile , & form ) {
714714 return
715715 }
716716
0 commit comments