Update golang dependencies
This commit is contained in:
parent
c5e30973e5
commit
9ddf98769a
1009 changed files with 175867 additions and 50378 deletions
6
vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go
generated
vendored
6
vendor/k8s.io/apimachinery/pkg/api/meta/restmapper.go
generated
vendored
|
|
@ -116,7 +116,7 @@ func NewDefaultRESTMapper(defaultGroupVersions []schema.GroupVersion, f VersionI
|
|||
}
|
||||
|
||||
func (m *DefaultRESTMapper) Add(kind schema.GroupVersionKind, scope RESTScope) {
|
||||
plural, singular := KindToResource(kind)
|
||||
plural, singular := UnsafeGuessKindToResource(kind)
|
||||
|
||||
m.singularToPlural[singular] = plural
|
||||
m.pluralToSingular[plural] = singular
|
||||
|
|
@ -136,10 +136,10 @@ var unpluralizedSuffixes = []string{
|
|||
"endpoints",
|
||||
}
|
||||
|
||||
// KindToResource converts Kind to a resource name.
|
||||
// UnsafeGuessKindToResource converts Kind to a resource name.
|
||||
// Broken. This method only "sort of" works when used outside of this package. It assumes that Kinds and Resources match
|
||||
// and they aren't guaranteed to do so.
|
||||
func KindToResource(kind schema.GroupVersionKind) ( /*plural*/ schema.GroupVersionResource /*singular*/, schema.GroupVersionResource) {
|
||||
func UnsafeGuessKindToResource(kind schema.GroupVersionKind) ( /*plural*/ schema.GroupVersionResource /*singular*/, schema.GroupVersionResource) {
|
||||
kindName := kind.Kind
|
||||
if len(kindName) == 0 {
|
||||
return schema.GroupVersionResource{}, schema.GroupVersionResource{}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue