Skip to content

Commit 43a936a

Browse files
committed
fix: use storedVersions to determine specific CR version
1 parent b29ef61 commit 43a936a

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pkg/collect/cluster_resources.go

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -797,6 +797,9 @@ func crsV1(ctx context.Context, client dynamic.Interface, config *rest.Config, n
797797
if len(crd.Spec.Versions) > 0 {
798798
version = crd.Spec.Versions[0].Name
799799
}
800+
if len(crd.Status.StoredVersions) > 0 {
801+
version = crd.Status.StoredVersions[0]
802+
}
800803
gvr := schema.GroupVersionResource{
801804
Group: crd.Spec.Group,
802805
Version: version,

0 commit comments

Comments
 (0)