xploitscan-shared-rules 1.11.0 → 1.11.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -841,7 +841,7 @@ function isCommentLine(content, matchIndex) {
841
841
  function isInsideFixMessage(content, matchIndex) {
842
842
  const lineStart = content.lastIndexOf("\n", matchIndex - 1) + 1;
843
843
  const lineText = content.substring(lineStart, content.indexOf("\n", matchIndex));
844
- return /(?:fix|description|message|suggestion|hint|help|example|doc|comment)\s*[:=(]/i.test(lineText) || /return\s*["'`].*\b(?:Use|Replace|Add|Move|Set|Enable|Disable|Never|Don't|Do not|Instead)\b/i.test(lineText);
844
+ return /(?:fix|description|message|suggestion|hint|help|example|doc|comment)\s*[:=]\s*["'`]/i.test(lineText) || /return\s*["'`].*\b(?:Use|Replace|Add|Move|Set|Enable|Disable|Never|Don't|Do not|Instead)\b/i.test(lineText);
845
845
  }
846
846
  function isInlineSilenced(content, matchIndex, ruleId) {
847
847
  const lines = content.split("\n");