Skip to content

Commit 4bafda0

Browse files
Copilotrchiodo
andcommitted
Update comment for regex 's' flag usage
Co-authored-by: rchiodo <19672699+rchiodo@users.noreply.github.com>
1 parent b673e61 commit 4bafda0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/extension/common/variables/environment.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,7 @@ function parseEnvLine(line: string): [string, string] {
176176
// https://github.com/motdotla/dotenv/blob/master/lib/main.js#L32
177177
// We don't use dotenv here because it loses ordering, which is
178178
// significant for substitution.
179-
// Modified to handle multiline values by using 's' flag to make . match newlines
179+
// Modified to handle multiline values by using 's' flag so $ matches before newlines in multiline strings
180180
const match = line.match(/^\s*(_*[a-zA-Z]\w*)\s*=\s*(.*?)?\s*$/s);
181181
if (!match) {
182182
return ['', ''];

0 commit comments

Comments
 (0)