Skip to content

Commit fef2932

Browse files
alexrfordhmac
andauthored
Apply suggestions from code review
Co-authored-by: Harry Maclean <[email protected]>
1 parent 16c5edd commit fef2932

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

ruby/ql/src/queries/modeling/internal/Summaries.qll

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ module Summaries {
3131
predicate summaryModel(string type, string path, string input, string output) {
3232
exists(DataFlow::MethodNode methodNode, API::Node paramNode |
3333
methodNode.getLocation().getFile() instanceof Util::RelevantFile and
34-
paramNode.getAValueReachableFromSource() = methodNode.getAReturnNode() and
34+
flow(paramNode.asSource(), methodNode.getAReturnNode()) and
3535
paramNode = getAnyParameterNode(methodNode)
3636
|
3737
Util::pathToMethod(methodNode, type, path) and
@@ -59,7 +59,7 @@ module Summaries {
5959
}
6060

6161
/**
62-
* Holds if calls to `(type, path)`, the value referred to by `input`
62+
* Holds if in calls to `(type, path)`, the value referred to by `input`
6363
* can flow to the value referred to by `output`.
6464
*
6565
* `kind` should be either `value` or `taint`, for value-preserving or taint-preserving steps,

ruby/ql/src/queries/modeling/internal/Types.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ private import Util as Util
1313
*/
1414
module Types {
1515
/**
16-
* Holds `node` should be seen as having the given `type`.
16+
* Holds if `node` should be seen as having the given `type`.
1717
*/
1818
private predicate valueHasTypeName(DataFlow::LocalSourceNode node, string type) {
1919
node.getLocation().getFile() instanceof Util::RelevantFile and

ruby/scripts/generate_model.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
#!/usr/bin/python3
1+
#!/usr/bin/env python3
22

33
# This script generates a data extensions model for a given library in codeql database form
44
# Currently only typeModels and summaryModels are generated
@@ -37,7 +37,7 @@ def parse_args():
3737
"-w",
3838
"--overwrite",
3939
action="store_true",
40-
help="if provided, use this command to invoke codeql",
40+
help="if provided, overwrite the file if it already exists",
4141
)
4242
return parser.parse_args()
4343

0 commit comments

Comments
 (0)