Move some code to make it reusable without import cycles.

This commit is contained in:
monopole
2021-01-14 10:10:10 -08:00
parent e92d048af2
commit b3fc306f6a
8 changed files with 122 additions and 107 deletions

View File

@@ -25,7 +25,7 @@ type Filter struct {
var _ kio.Filter = Filter{}
func (f Filter) Filter(nodes []*yaml.RNode) ([]*yaml.RNode, error) {
keys := filtersutil.SortedMapKeys(f.Labels)
keys := yaml.SortedMapKeys(f.Labels)
_, err := kio.FilterAll(yaml.FilterFunc(
func(node *yaml.RNode) (*yaml.RNode, error) {
for _, k := range keys {