This commit is contained in:
Jeff Carr 2025-01-19 09:25:25 -06:00
parent ab9f3bf62d
commit ae24f02bbb
1 changed files with 5 additions and 3 deletions

View File

@ -303,10 +303,12 @@ func forceDeleteUserBranch(repo *gitpb.Repo, branch string) error {
log.Info(err) log.Info(err)
return err return err
} }
if repo.Exists(filepath.Join(".git/refs/remotes/origin/", branch)) {
if err := requiresGitPush(repo, branch); err != nil { if err := requiresGitPush(repo, branch); err != nil {
log.Info(err) log.Info(err)
return err return err
} }
}
configSave = true configSave = true
cmd := []string{"git", "branch", "-D", branch} cmd := []string{"git", "branch", "-D", branch}