Skip to content

Commit 74a79f8

Browse files
erik-kroghasgerf
andcommitted
simplify int check
Co-authored-by: Asger F <asgerf@github.com>
1 parent 73a9361 commit 74a79f8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

javascript/ql/lib/semmle/javascript/security/dataflow/ClientSideUrlRedirectCustomizations.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ module ClientSideUrlRedirect {
6767
methodName = StringOps::substringMethodName() and
6868
// exclude `location.href.substring(0, ...)` and similar, which can
6969
// never refer to the query string
70-
not mcn.getArgument(0).asExpr().(NumberLiteral).getIntValue() = 0
70+
not mcn.getArgument(0).getIntValue() = 0
7171
)
7272
or
7373
exists(DataFlow::MethodCallNode mcn |

0 commit comments

Comments
 (0)