JS: previously js/case-sensitive-middleware-path was not taking into consideration unknown flags

This commit is contained in:
Napalys
2024-11-25 11:56:06 +01:00
parent 178da21fb8
commit e38b63ebcd
3 changed files with 3 additions and 2 deletions

View File

@@ -65,7 +65,7 @@ predicate isCaseSensitiveMiddleware(
arg = call.getArgument(0) and
regexp.getAReference().flowsTo(arg) and
exists(string flags |
flags = regexp.getFlags() and
flags = regexp.tryGetFlags() and
not RegExp::isIgnoreCase(flags)
)
)