Fix error not returned error

This commit is contained in:
Chongyi Zheng 2022-07-11 23:25:43 -04:00
parent fb82294fc6
commit 22835e4375
No known key found for this signature in database
GPG Key ID: CC2953E050C19686
1 changed files with 3 additions and 0 deletions

View File

@ -437,6 +437,9 @@ func UpdateLabelsByRepoID(repoID int64, labels ...*Label) error {
defer committer.Close()
existingLabels, err := GetLabelsByRepoID(ctx, repoID, "", db.ListOptions{})
if err != nil {
return err
}
labelsToAdd := make([]*Label, 0)
labelsToUpdate := make([]*Label, 0)
labelsToDelete := make([]*Label, 0)