From dfe9d3a1da56b08f78a3ef7a73de4b2dfe6e0c6a Mon Sep 17 00:00:00 2001 From: Raymond Hill Date: Sun, 1 Jan 2023 21:58:14 -0500 Subject: [PATCH] Fix missing regex flags Related feedback: - https://www.reddit.com/r/uBlockOrigin/comments/1005a8f/suddenly_my_filters_doesnt_work/j2htwof/ --- src/js/contentscript-extra.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/js/contentscript-extra.js b/src/js/contentscript-extra.js index 78689f84c..344165693 100644 --- a/src/js/contentscript-extra.js +++ b/src/js/contentscript-extra.js @@ -36,7 +36,7 @@ const nonVisualElements = { const regexFromString = (s, exact = false) => { if ( s === '' ) { return /^/; } - const match = /^\/(.+)\/([i]?)$/.exec(s); + const match = /^\/(.+)\/([imu]*)$/.exec(s); if ( match !== null ) { return new RegExp(match[1], match[2] || undefined); }