1
1
mirror of https://github.com/go-gitea/gitea synced 2025-07-22 18:28:37 +00:00

Fix push multiple branches error with tests (#31151)

This commit is contained in:
Lunny Xiao
2024-05-29 14:43:02 +08:00
committed by GitHub
parent 7034efc7dc
commit 5c1b550e00
3 changed files with 54 additions and 1 deletions

View File

@@ -332,7 +332,7 @@ func SyncBranchesToDB(ctx context.Context, repoID, pusherID int64, branchNames,
if _, err := git_model.UpdateBranch(ctx, repoID, pusherID, branchName, commit); err != nil {
return fmt.Errorf("git_model.UpdateBranch %d:%s failed: %v", repoID, branchName, err)
}
return nil
continue
}
// if database have branches but not this branch, it means this is a new branch