Browse Source

Fix #9752 (#9769)

for-closed-social
zeripath 4 years ago
committed by GitHub
parent
commit
d171cd41b1
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      modules/repofiles/delete.go

+ 1
- 1
modules/repofiles/delete.go View File

@ -47,7 +47,7 @@ func DeleteRepoFile(repo *models.Repository, doer *models.User, opts *DeleteRepo
// If we aren't branching to a new branch, make sure user can commit to the given branch
if opts.NewBranch != opts.OldBranch {
newBranch, err := repo_module.GetBranch(repo, opts.NewBranch)
if git.IsErrNotExist(err) {
if err != nil && !git.IsErrBranchNotExist(err) {
return nil, err
}
if newBranch != nil {

Loading…
Cancel
Save