Move the discovery client to its own package
This commit is contained in:
@@ -92,3 +92,13 @@ func FormatLabelSelector(labelSelector *LabelSelector) string {
|
||||
}
|
||||
return l
|
||||
}
|
||||
|
||||
func ExtractGroupVersions(l *APIGroupList) []string {
|
||||
var groupVersions []string
|
||||
for _, g := range l.Groups {
|
||||
for _, gv := range g.Versions {
|
||||
groupVersions = append(groupVersions, gv.GroupVersion)
|
||||
}
|
||||
}
|
||||
return groupVersions
|
||||
}
|
||||
|
Reference in New Issue
Block a user