Skip to content

Commit 0c3daab

Browse files
committed
JS: Fix broken regex matching predicate
The receiver string and the regex were in the wrong order, leading to test failures when looking for matching comments.
1 parent 322e394 commit 0c3daab

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

javascript/ql/lib/semmle/javascript/dependencies/FrameworkLibraries.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -238,7 +238,7 @@ private class MarkerComment extends Comment {
238238
* with version number `version`.
239239
*/
240240
predicate matchesFramework(FrameworkLibraryWithMarkerComment fl, string version) {
241-
fl.getAMarkerCommentRegexWithoutPlaceholders().regexpCapture(this.getText(), 1) = version
241+
this.getText().regexpCapture(fl.getAMarkerCommentRegexWithoutPlaceholders(), 1) = version
242242
}
243243
}
244244

0 commit comments

Comments
 (0)