Skip to content

Commit e132c00

Browse files
committed
fix edge case
1 parent 0fe513e commit e132c00

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/node_dotenv.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ std::vector<std::string> Dotenv::GetPathFromArgs(
2525
paths.push_back(arg.substr(11)); // Directly extract the path
2626
} else if (arg == "--env-file" && i + 1 < args.size()) {
2727
paths.push_back(args[++i]); // Advance to the next argument
28-
}
28+
} else if (arg[1] != '-') ++i;
2929
}
3030
return paths;
3131
}

0 commit comments

Comments
 (0)