Skip to content

Commit 9586259

Browse files
authored
style tweak for checking multiple method names
1 parent a1df1d1 commit 9586259

1 file changed

Lines changed: 2 additions & 7 deletions

File tree

ruby/ql/src/experimental/weak-params/WeakParams.ql

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -38,13 +38,8 @@ class ActionControllerRequest extends DataFlow::Node {
3838
class WeakParams extends DataFlow::CallNode {
3939
WeakParams() {
4040
this.getReceiver() instanceof ActionControllerRequest and
41-
(
42-
this.getMethodName() = "path_parametes" or
43-
this.getMethodName() = "query_parameters" or
44-
this.getMethodName() = "request_parameters" or
45-
this.getMethodName() = "GET" or
46-
this.getMethodName() = "POST"
47-
)
41+
this.getMethodName() =
42+
["path_parametes", "query_parameters", "request_parameters", "GET", "POST"]
4843
}
4944
}
5045

0 commit comments

Comments
 (0)