mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-11-03 15:25:19 +00:00
Merge pull request #18855 from deads2k/gv-stop-reverse
Auto commit by PR queue bot
This commit is contained in:
@@ -65,18 +65,13 @@ func init() {
|
||||
}
|
||||
|
||||
func newRESTMapper(externalVersions []unversioned.GroupVersion) meta.RESTMapper {
|
||||
worstToBestGroupVersions := []unversioned.GroupVersion{}
|
||||
for i := len(externalVersions) - 1; i >= 0; i-- {
|
||||
worstToBestGroupVersions = append(worstToBestGroupVersions, externalVersions[i])
|
||||
}
|
||||
|
||||
// the list of kinds that are scoped at the root of the api hierarchy
|
||||
// if a kind is not enumerated here, it is assumed to have a namespace scope
|
||||
rootScoped := sets.NewString()
|
||||
|
||||
ignoredKinds := sets.NewString()
|
||||
|
||||
return api.NewDefaultRESTMapper(worstToBestGroupVersions, interfacesFor, importPrefix, ignoredKinds, rootScoped)
|
||||
return api.NewDefaultRESTMapper(externalVersions, interfacesFor, importPrefix, ignoredKinds, rootScoped)
|
||||
}
|
||||
|
||||
// InterfacesFor returns the default Codec and ResourceVersioner for a given version
|
||||
|
||||
Reference in New Issue
Block a user