mirror of
https://github.com/github/codeql.git
synced 2026-05-05 05:35:13 +02:00
JS: add simple variants of StringOps::EndsWith
This commit is contained in:
@@ -0,0 +1 @@
|
||||
| tst.js:5:7:5:19 | A.endsWith(B) | tst.js:5:7:5:7 | A | tst.js:5:18:5:18 | B | true |
|
||||
@@ -0,0 +1,4 @@
|
||||
import javascript
|
||||
|
||||
from StringOps::EndsWith endsWith
|
||||
select endsWith, endsWith.getBaseString(), endsWith.getSubstring(), endsWith.getPolarity()
|
||||
@@ -0,0 +1,8 @@
|
||||
import * as _ from 'underscore';
|
||||
import * as R from 'ramda';
|
||||
|
||||
function test() {
|
||||
if (A.endsWith(B)) {}
|
||||
if (_.endsWith(A, B)) {}
|
||||
if (R.endsWith(A, B)) {}
|
||||
}
|
||||
Reference in New Issue
Block a user