Skip to content

Commit

Permalink
use sync map
Browse files Browse the repository at this point in the history
Signed-off-by: Coleen Iona Quadros <coleen.quadros27@gmail.com>
  • Loading branch information
coleenquadros committed Sep 25, 2024
1 parent b0d0c90 commit 2db9457
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,9 @@ func getClusterPreds() predicate.Funcs {
return false
}

delete(managedClusterImageRegistry, e.Object.GetName())
if e.Object.GetName() != localClusterName {
updateManagedClusterList(e.Object)
}
managedClusterImageRegistryMutex.Lock()
delete(managedClusterImageRegistry, e.Object.GetName())
managedClusterImageRegistryMutex.Unlock()
Expand Down

0 comments on commit 2db9457

Please sign in to comment.