mirror of
https://gh.wpcy.net/https://github.com/verygoodplugins/freescout-gpt-assistant.git
synced 2026-05-28 02:53:10 +08:00
forEach loop doesn't properly handle regex flag state The DANGEROUS_PATTERNS array contains regex patterns with the global flag (/gi). When used in a forEach loop, these regexes maintain state between matches which could cause unexpected behavior. Reset the regex state or avoid the global flag when using test() Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com> |
||
|---|---|---|
| .. | ||
| htmlSanitizer.js | ||