From d7c914bab4a38928cdcd176ecbf03c403c1931a7 Mon Sep 17 00:00:00 2001 From: shiywang Date: Mon, 9 Jan 2017 22:29:05 +0800 Subject: [PATCH] remove unused parameter --- pkg/genericapiserver/api/handlers/rest.go | 2 +- pkg/genericapiserver/api/installer.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/genericapiserver/api/handlers/rest.go b/pkg/genericapiserver/api/handlers/rest.go index ec7563cbbe9..f3f2f5bd734 100644 --- a/pkg/genericapiserver/api/handlers/rest.go +++ b/pkg/genericapiserver/api/handlers/rest.go @@ -451,7 +451,7 @@ func (c *namedCreaterAdapter) Create(ctx request.Context, name string, obj runti // PatchResource returns a function that will handle a resource patch // TODO: Eventually PatchResource should just use GuaranteedUpdate and this routine should be a bit cleaner -func PatchResource(r rest.Patcher, scope RequestScope, typer runtime.ObjectTyper, admit admission.Interface, converter runtime.ObjectConvertor) restful.RouteFunction { +func PatchResource(r rest.Patcher, scope RequestScope, admit admission.Interface, converter runtime.ObjectConvertor) restful.RouteFunction { return func(req *restful.Request, res *restful.Response) { w := res.ResponseWriter diff --git a/pkg/genericapiserver/api/installer.go b/pkg/genericapiserver/api/installer.go index 63c5b466e3b..28b29450e0b 100644 --- a/pkg/genericapiserver/api/installer.go +++ b/pkg/genericapiserver/api/installer.go @@ -634,7 +634,7 @@ func (a *APIInstaller) registerResourceHandlers(path string, storage rest.Storag if hasSubresource { doc = "partially update " + subresource + " of the specified " + kind } - handler := metrics.InstrumentRouteFunc(action.Verb, resource, handlers.PatchResource(patcher, reqScope, a.group.Typer, admit, mapping.ObjectConvertor)) + handler := metrics.InstrumentRouteFunc(action.Verb, resource, handlers.PatchResource(patcher, reqScope, admit, mapping.ObjectConvertor)) route := ws.PATCH(action.Path).To(handler). Doc(doc). Param(ws.QueryParameter("pretty", "If 'true', then the output is pretty printed.")).