File tree Expand file tree Collapse file tree 1 file changed +11
-2
lines changed
ruby/ql/lib/codeql/ruby/frameworks Expand file tree Collapse file tree 1 file changed +11
-2
lines changed Original file line number Diff line number Diff line change @@ -43,8 +43,17 @@ module ActionCable {
43
43
.getConstant ( "Channel" )
44
44
.getConstant ( "Base" )
45
45
.getADescendentModule ( )
46
- .getAnOwnInstanceMethod ( ) and
47
- // as long as it's public
46
+ .getAnInstanceMethod ( ) and
47
+ // as long as it's not an instance method of
48
+ // `ActionCable::Channel::Base` itself, which might exist in the
49
+ // database
50
+ not m =
51
+ DataFlow:: getConstant ( "ActionCable" )
52
+ .getConstant ( "Channel" )
53
+ .getConstant ( "Base" )
54
+ .asModule ( )
55
+ .getAnInstanceMethod ( ) and
56
+ // and as long as it's public
48
57
m .asCallableAstNode ( ) .isPublic ( ) and
49
58
// and is not called `subscribed` or `unsubscribed`.
50
59
not m .getMethodName ( ) = [ "subscribed" , "unsubscribed" ]
You can’t perform that action at this time.
0 commit comments