From 2beab4cc142d01938c836b67366696982d0e1d46 Mon Sep 17 00:00:00 2001 From: Daniel Wilson Date: Wed, 15 Nov 2023 10:25:31 +0000 Subject: [PATCH] fix logic --- plugin/builtin/sortordertransformer/SortOrderTransformer.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugin/builtin/sortordertransformer/SortOrderTransformer.go b/plugin/builtin/sortordertransformer/SortOrderTransformer.go index 2f3ef83ab5..61c62f29c9 100644 --- a/plugin/builtin/sortordertransformer/SortOrderTransformer.go +++ b/plugin/builtin/sortordertransformer/SortOrderTransformer.go @@ -166,7 +166,7 @@ func gvkLessThan(gvk1, gvk2 resid.Gvk, typeOrders map[string]int) bool { if (gvk1.Kind == types.NamespaceKind && gvk2.Kind == types.NamespaceKind) && (gvk1.Group == "" || gvk2.Group == "") { return legacyGVKSortString(gvk1) > legacyGVKSortString(gvk2) } - return legacyGVKSortString(gvk1) < legacyGVKSortString(gvk) + return legacyGVKSortString(gvk1) < legacyGVKSortString(gvk2) } // legacyGVKSortString returns a string representation of given GVK used for