Skip to content

Commit 664bad2

Browse files
lpcoxCopilot
andauthored
Potential fix for pull request finding
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
1 parent 8e751f8 commit 664bad2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

internal/envutil/expand_env_args.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ func WalkDockerEnvArgs(args []string, fn func(index int, varName, value string,
1818
arg := args[i]
1919
if arg == "-e" && i+1 < len(args) {
2020
nextArg := args[i+1]
21-
if !strings.Contains(nextArg, "=") {
21+
if nextArg != "" && !strings.Contains(nextArg, "=") {
2222
value, found := os.LookupEnv(nextArg)
2323
fn(i, nextArg, value, found)
2424
}

0 commit comments

Comments
 (0)