Remove unused selflink parameters from ContextBasedNaming

Kubernetes-commit: 1e0b9c6e20a07f706e7ace39f417ea746fa05a3b
This commit is contained in:
Wojciech Tyczyński 2022-01-14 10:00:04 +01:00 committed by Kubernetes Publisher
parent 5e8e1ff118
commit 8268596b30
2 changed files with 4 additions and 12 deletions

View File

@ -41,9 +41,6 @@ type ScopeNamer interface {
type ContextBasedNaming struct {
Namer runtime.Namer
ClusterScoped bool
SelfLinkPathPrefix string
SelfLinkPathSuffix string
}
// ContextBasedNaming implements ScopeNamer

View File

@ -19,7 +19,6 @@ package endpoints
import (
"fmt"
"net/http"
gpath "path"
"reflect"
"sort"
"strings"
@ -430,8 +429,6 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
namer := handlers.ContextBasedNaming{
Namer: a.group.Namer,
ClusterScoped: true,
SelfLinkPathPrefix: gpath.Join(a.prefix, resource) + "/",
SelfLinkPathSuffix: suffix,
}
// Handler for standard REST verbs (GET, PUT, POST and DELETE).
@ -479,8 +476,6 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag
namer := handlers.ContextBasedNaming{
Namer: a.group.Namer,
ClusterScoped: false,
SelfLinkPathPrefix: gpath.Join(a.prefix, namespaceParamName) + "/",
SelfLinkPathSuffix: itemPathSuffix,
}
actions = appendIf(actions, action{"LIST", resourcePath, resourceParams, namer, false}, isLister)