Fixing the check to determine if the resource is namespaced

This commit is contained in:
nikhiljindal 2016-03-16 17:46:05 -07:00
parent 067b1323d3
commit 96044b7f43

View File

@ -464,7 +464,7 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
for _, action := range actions { for _, action := range actions {
reqScope.Namer = action.Namer reqScope.Namer = action.Namer
namespaced := "" namespaced := ""
if strings.Contains(action.Path, scope.ArgumentName()) { if apiResource.Namespaced {
namespaced = "Namespaced" namespaced = "Namespaced"
} }
switch action.Verb { switch action.Verb {