diff --git a/vendor.conf b/vendor.conf index 29f7502d..359f398a 100644 --- a/vendor.conf +++ b/vendor.conf @@ -3,5 +3,5 @@ github.com/rancher/types k8s.io/kubernetes v1.8.3 transitive=true,staging=true bitbucket.org/ww/goautoneg a547fc61f48d567d5b4ec6f8aee5573d8efce11d https://github.com/rancher/goautoneg.git -github.com/rancher/norman 16783cf1d364fa9d1e62d0b4ecfd1f919a956da4 +github.com/rancher/norman b80039523f49e7bfd335031ac82208f1bbf6bd40 golang.org/x/sync fd80eb99c8f653c847d294a001bdf2a3a6f768f5 diff --git a/vendor/github.com/rancher/norman/types/mapper.go b/vendor/github.com/rancher/norman/types/mapper.go index a8913418..68b22b87 100644 --- a/vendor/github.com/rancher/norman/types/mapper.go +++ b/vendor/github.com/rancher/norman/types/mapper.go @@ -74,7 +74,12 @@ func (t *typeMapper) FromInternal(data map[string]interface{}) { name, _ := data["name"].(string) namespace, _ := data["namespaceId"].(string) - if _, ok := data["id"]; !ok { + if _, ok := data["id"]; ok { + if namespace != "" { + id, _ := data["id"].(string) + data["id"] = namespace + ":" + id + } + } else { if name != "" { if namespace == "" { data["id"] = name diff --git a/vendor/github.com/rancher/norman/types/reflection.go b/vendor/github.com/rancher/norman/types/reflection.go index 61192ce2..44b4b926 100644 --- a/vendor/github.com/rancher/norman/types/reflection.go +++ b/vendor/github.com/rancher/norman/types/reflection.go @@ -52,8 +52,6 @@ func (s *Schemas) AddMapperForType(version *APIVersion, obj interface{}, mapper } func (s *Schemas) MustImport(version *APIVersion, obj interface{}, externalOverrides ...interface{}) *Schemas { - //TODO: remove - logrus.SetLevel(logrus.DebugLevel) if _, err := s.Import(version, obj, externalOverrides...); err != nil { panic(err) }