From d27f6a61a26c69e10ff8b4124c2dabce75606f90 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Mon, 17 Feb 2025 13:51:37 +0100 Subject: [PATCH] cli/registry: fix "unused-receiver" linting cli/registry/client/fetcher.go:307:7: unused-receiver: method receiver 'n' is not referenced in method's body, consider removing or renaming it as _ (revive) func (n *notFoundError) NotFound() {} ^ cli/registry/client/endpoint.go:126:7: unused-receiver: method receiver 'th' is not referenced in method's body, consider removing or renaming it as _ (revive) func (th *existingTokenHandler) Scheme() string { ^ Signed-off-by: Sebastiaan van Stijn --- cli/registry/client/endpoint.go | 2 +- cli/registry/client/fetcher.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cli/registry/client/endpoint.go b/cli/registry/client/endpoint.go index 2446da85a0..95312b0558 100644 --- a/cli/registry/client/endpoint.go +++ b/cli/registry/client/endpoint.go @@ -123,6 +123,6 @@ func (th *existingTokenHandler) AuthorizeRequest(req *http.Request, _ map[string return nil } -func (th *existingTokenHandler) Scheme() string { +func (*existingTokenHandler) Scheme() string { return "bearer" } diff --git a/cli/registry/client/fetcher.go b/cli/registry/client/fetcher.go index 3e4b36d309..d1f255bf9f 100644 --- a/cli/registry/client/fetcher.go +++ b/cli/registry/client/fetcher.go @@ -304,4 +304,4 @@ func (n *notFoundError) Error() string { } // NotFound satisfies interface github.com/docker/docker/errdefs.ErrNotFound -func (n *notFoundError) NotFound() {} +func (notFoundError) NotFound() {}