Merge pull request #4117 from backstage/freben/secwarn

chore: silence code quality warning about backslash escape
This commit is contained in:
Fredrik Adelöw
2021-01-17 16:03:45 +01:00
committed by GitHub
+1 -1
View File
@@ -152,7 +152,7 @@ export async function waitForPageWithText(
// The page may not be fully loaded and hence we need to retry.
let findTextAttempts = 0;
const escapedText = text.replace(/"/g, '\\"');
const escapedText = text.replace(/"|\\/g, '\\$&');
for (;;) {
try {
browser.assert.evaluate(