Annotations: Prevent orphaned annotation tags cleanup when no annotations were cleaned (#33957)
Fixes #33948 Co-authored-by: Anatoly Fayngelerin <afayngelerin@dropbox.com>
This commit is contained in:
co-authored by
Anatoly Fayngelerin
parent
c6dd19f163
commit
b0094b325e
@@ -47,8 +47,9 @@ func (acs *AnnotationCleanupService) CleanAnnotations(ctx context.Context, cfg *
|
||||
if err != nil {
|
||||
return totalCleanedAnnotations, 0, err
|
||||
}
|
||||
|
||||
affected, err = acs.cleanOrphanedAnnotationTags(ctx)
|
||||
if totalCleanedAnnotations > 0 {
|
||||
affected, err = acs.cleanOrphanedAnnotationTags(ctx)
|
||||
}
|
||||
return totalCleanedAnnotations, affected, err
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user