Skip to content

Commit 4b3d995

Browse files
committed
Ruby: rack - rename getResponse as getAResponse
1 parent 4f9f41a commit 4b3d995

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

ruby/ql/lib/codeql/ruby/frameworks/rack/internal/App.qll

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,8 @@ private class CallNode extends PotentialCallNode {
4040

4141
CallNode() { resp = trackRackResponse(this) }
4242

43-
/** Gets the response returned from a request to this application. */
44-
RP::PotentialResponseNode getResponse() { result = resp }
43+
/** Gets a response returned from a request to this application. */
44+
RP::PotentialResponseNode getAResponse() { result = resp }
4545
}
4646

4747
private DataFlow::LocalSourceNode trackRackResponse(TypeBackTracker t, PotentialCallNode call) {
@@ -82,7 +82,7 @@ module App {
8282

8383
/** Gets the response returned from a request to this application. */
8484
RP::PotentialResponseNode getResponse() { result = resp }
85-
}
85+
}
8686

8787
private newtype TApp =
8888
TClassApp(DataFlow::ClassNode cn, CallNode call) or
@@ -100,8 +100,8 @@ module App {
100100
/** Gets the `DataFlow::CallableNode` that will handle requests to this app. */
101101
abstract CallNode getCall();
102102

103-
/** Gets the response returned from a request to this app. */
104-
RP::PotentialResponseNode getResponse() { result = this.getCall().getResponse() }
103+
/** Gets a response returned from a request to this app. */
104+
RP::PotentialResponseNode getAResponse() { result = this.getCall().getAResponse() }
105105

106106
/** Gets the `env` parameter passed to this app when it handles a request. */
107107
DataFlow::ParameterNode getEnv() { result = this.getCall().getParameter(0) }

ruby/ql/lib/codeql/ruby/frameworks/rack/internal/Response.qll

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ module Public {
9191
/** A `DataFlow::Node` returned from a rack request. */
9292
class ResponseNode extends Http::Server::HttpResponse::Range instanceof Private::PotentialResponseNode
9393
{
94-
ResponseNode() { this = any(A::App::App app).getResponse() }
94+
ResponseNode() { this = any(A::App::App app).getAResponse() }
9595

9696
override DataFlow::Node getBody() { result = this.(Private::PotentialResponseNode).getBody() }
9797

0 commit comments

Comments
 (0)