Skip to content

Commit

Permalink
Implements suggestions from developer review to remove unnecessary co…
Browse files Browse the repository at this point in the history
…nditional
  • Loading branch information
jonathanmccormack authored and lbajolet-hashicorp committed Nov 22, 2024
1 parent 3f79c7c commit 4473e6e
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions builder/docker/dockerfile_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -99,11 +99,9 @@ func (c DockerfileBootstrapConfig) BuildArgs() []string {
}

// Loops through map of build arguments to add to build command
if len(c.Arguments) > 0 {
for key, value := range c.Arguments {
arg := key + "=" + value
retArgs = append(retArgs, "--build-arg", arg)
}
for key, value := range c.Arguments {
arg := key + "=" + value
retArgs = append(retArgs, "--build-arg", arg)
}

return append(retArgs, c.BuildDir)
Expand Down

0 comments on commit 4473e6e

Please sign in to comment.