mirror of
https://github.com/github/codeql.git
synced 2026-04-26 09:15:12 +02:00
Ruby: Fix <<
This commit is contained in:
@@ -618,7 +618,9 @@ private class ActiveRecordAssociationMethodCall extends DataFlow::CallNode {
|
||||
(
|
||||
assoc.isCollection() and
|
||||
(
|
||||
this.getMethodName() = pluralize(model) + ["", "=", "<<"]
|
||||
this.getMethodName() = pluralize(model) + ["", "="]
|
||||
or
|
||||
this.getMethodName() = "<<"
|
||||
or
|
||||
this.getMethodName() = model + ["_ids", "_ids="]
|
||||
)
|
||||
|
||||
@@ -39,6 +39,7 @@ activeRecordInstances
|
||||
| associations.rb:27:9:27:28 | call to create |
|
||||
| associations.rb:29:1:29:7 | author2 |
|
||||
| associations.rb:29:1:29:13 | call to posts |
|
||||
| associations.rb:29:1:29:22 | ... << ... |
|
||||
| associations.rb:29:18:29:22 | post2 |
|
||||
| associations.rb:31:1:31:5 | post1 |
|
||||
| associations.rb:31:1:31:12 | __synth__0 |
|
||||
@@ -175,6 +176,8 @@ activeRecordModelInstantiations
|
||||
| associations.rb:27:9:27:21 | call to posts | associations.rb:5:1:9:3 | Post |
|
||||
| associations.rb:27:9:27:28 | call to create | associations.rb:5:1:9:3 | Post |
|
||||
| associations.rb:29:1:29:13 | call to posts | associations.rb:5:1:9:3 | Post |
|
||||
| associations.rb:29:1:29:22 | ... << ... | associations.rb:11:1:13:3 | Tag |
|
||||
| associations.rb:29:1:29:22 | ... << ... | associations.rb:15:1:17:3 | Comment |
|
||||
| associations.rb:31:1:31:12 | call to author= | associations.rb:1:1:3:3 | Author |
|
||||
| associations.rb:35:1:35:14 | call to comments | associations.rb:15:1:17:3 | Comment |
|
||||
| associations.rb:35:1:35:21 | call to create | associations.rb:15:1:17:3 | Comment |
|
||||
|
||||
Reference in New Issue
Block a user