Skip to content

Commit

Permalink
added '\' escapes (elastic#199185)
Browse files Browse the repository at this point in the history
## Summary

This PR adds backslash escaping to previous code scan fixes.
  • Loading branch information
bryce-b authored and mgadewoll committed Nov 7, 2024
1 parent d6b4f2f commit a9a069c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ export const createFilterFromOptions = (
filters.push(options.filterQuery);
}
if (options.groupBy) {
const id = series.id.replace(/"/g, '\\"');
const id = series.id.replace(/\\/g, '\\\\').replace(/"/g, '\\"');
const groupByFilters = Array.isArray(options.groupBy)
? options.groupBy
.map((field, index) => {
Expand Down

0 comments on commit a9a069c

Please sign in to comment.