From 0d68b2b412b4414711b3942036329800fc35e457 Mon Sep 17 00:00:00 2001 From: Gabe Cook Date: Thu, 24 Mar 2022 00:38:50 -0500 Subject: [PATCH] :rotating_light: Fix lint warnings --- internal/command/builder.go | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/internal/command/builder.go b/internal/command/builder.go index daad3d3a..371627ff 100644 --- a/internal/command/builder.go +++ b/internal/command/builder.go @@ -29,13 +29,13 @@ func (j *Builder) Unshift(p ...any) *Builder { func (j Builder) Join() string { var buf strings.Builder for k, v := range j.cmd { - switch v.(type) { + switch v := v.(type) { case string: - buf.WriteString(shellescape.Quote(v.(string))) + buf.WriteString(shellescape.Quote(v)) case Env: - buf.WriteString(v.(Env).String()) + buf.WriteString(v.String()) case Raw: - buf.WriteString(string(v.(Raw))) + buf.WriteString(string(v)) default: panic(fmt.Errorf("unknown value in command: %#v", v)) }