mirror of
https://github.com/denoland/deno.git
synced 2025-03-03 09:31:22 -05:00
Typo (#9221)
This commit is contained in:
parent
bdb1ee6480
commit
ffa920e4b9
1 changed files with 1 additions and 1 deletions
|
@ -17,7 +17,7 @@ function getEscapedString(value: unknown, sep: string): string {
|
|||
if (typeof value === "object") str = JSON.stringify(value);
|
||||
else str = String(value);
|
||||
|
||||
// Is regex.test more performance here? If so, how to dynamically create?
|
||||
// Is regex.test more performant here? If so, how to dynamically create?
|
||||
// https://stackoverflow.com/questions/3561493/
|
||||
if (str.includes(sep) || str.includes(NEWLINE) || str.includes(QUOTE)) {
|
||||
return `${QUOTE}${str.replaceAll(QUOTE, `${QUOTE}${QUOTE}`)}${QUOTE}`;
|
||||
|
|
Loading…
Add table
Reference in a new issue