support empty label filter
Signed-off-by: hongming <talonwan@yunify.com>
This commit is contained in:
@@ -48,7 +48,8 @@ func (*workspaceSearcher) match(match map[string]string, item *v1alpha1.Workspac
|
||||
return false
|
||||
}
|
||||
default:
|
||||
if item.Labels[k] != v {
|
||||
// label not exist or value not equal
|
||||
if val, ok := item.Labels[k]; !ok || val != v {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user