golangci-lint: revive: enable import-shadowing
Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
@ -224,8 +224,8 @@ func configFromName(name string) swarm.Config {
|
||||
}
|
||||
}
|
||||
|
||||
func namespaceFromFilters(filters filters.Args) string {
|
||||
label := filters.Get("label")[0]
|
||||
func namespaceFromFilters(fltrs filters.Args) string {
|
||||
label := fltrs.Get("label")[0]
|
||||
return strings.TrimPrefix(label, convert.LabelNamespace+"=")
|
||||
}
|
||||
|
||||
|
||||
@ -46,8 +46,8 @@ func newConfigCommand(dockerCli command.Cli) *cobra.Command {
|
||||
|
||||
// outputConfig returns the merged and interpolated config file
|
||||
func outputConfig(configFiles composetypes.ConfigDetails, skipInterpolation bool) (string, error) {
|
||||
optsFunc := func(options *composeLoader.Options) {
|
||||
options.SkipInterpolation = skipInterpolation
|
||||
optsFunc := func(opts *composeLoader.Options) {
|
||||
opts.SkipInterpolation = skipInterpolation
|
||||
}
|
||||
config, err := composeLoader.Load(configFiles, optsFunc)
|
||||
if err != nil {
|
||||
|
||||
@ -213,8 +213,8 @@ func configFromName(name string) swarm.Config {
|
||||
}
|
||||
}
|
||||
|
||||
func namespaceFromFilters(filters filters.Args) string {
|
||||
label := filters.Get("label")[0]
|
||||
func namespaceFromFilters(fltrs filters.Args) string {
|
||||
label := fltrs.Get("label")[0]
|
||||
return strings.TrimPrefix(label, convert.LabelNamespace+"=")
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user