This commit is contained in:
harryzcy 2023-05-07 18:20:29 -04:00
parent 3a72ed9835
commit ef82e4e22c
No known key found for this signature in database
GPG Key ID: E3C2287691E40E35
1 changed files with 4 additions and 6 deletions

View File

@ -458,12 +458,10 @@ func UpdateLabelsByRepoID(repoID int64, labels ...*Label) error {
if foundLabel == nil {
labelsToAdd = append(labelsToAdd, l)
} else {
if foundLabel.Name != l.Name || foundLabel.Description != l.Description ||
foundLabel.Color != l.Color {
l.RepoID = repoID
labelsToUpdate = append(labelsToUpdate, l)
}
} else if foundLabel.Name != l.Name || foundLabel.Description != l.Description ||
foundLabel.Color != l.Color {
l.RepoID = repoID
labelsToUpdate = append(labelsToUpdate, l)
}
}