From d77760fe5303c465f0565a16bad5d8ddbb7a0cec Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Tue, 5 Nov 2024 10:11:46 +0100 Subject: [PATCH] cli-plugins/manager: remove redundant capturing of loop vars (copyloopvar) go1.22 and up now produce a unique variable in loops, tehrefore no longer requiring to capture the variable manually; cli-plugins/manager/cobra.go:55:4: The copy of the 'for' variable "p" can be deleted (Go 1.22+) (copyloopvar) p := p ^ Signed-off-by: Sebastiaan van Stijn --- cli-plugins/manager/cobra.go | 1 - 1 file changed, 1 deletion(-) diff --git a/cli-plugins/manager/cobra.go b/cli-plugins/manager/cobra.go index 9d09018001..4bfa06fa5c 100644 --- a/cli-plugins/manager/cobra.go +++ b/cli-plugins/manager/cobra.go @@ -52,7 +52,6 @@ func AddPluginCommandStubs(dockerCli command.Cli, rootCmd *cobra.Command) (err e return } for _, p := range plugins { - p := p vendor := p.Vendor if vendor == "" { vendor = "unknown"