Skip to content

Commit

Permalink
Fix code scanning alert no. 456: Incomplete string escaping or encoding
Browse files Browse the repository at this point in the history
Co-authored-by: Copilot Autofix powered by AI <62310815+github-advanced-security[bot]@users.noreply.github.com>
  • Loading branch information
smith and github-advanced-security[bot] authored Sep 24, 2024
1 parent 6ff0791 commit 998d2a8
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,7 @@ export const createFilterFromOptions = (
if (!value) {
return null;
}
return `${field}: "${value.replace(/"/g, '\\"')}"`;
return `${field}: "${value.replace(/\\/g, '\\\\').replace(/"/g, '\\"')}"`;
})
.join(' and ')
: `${options.groupBy} : "${id}"`;
Expand Down

0 comments on commit 998d2a8

Please sign in to comment.