Skip to content

Commit 8231907

Browse files
committed
Ratpack code cleanup from code review
1 parent db2892b commit 8231907

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

java/ql/lib/semmle/code/java/frameworks/ratpack/RatpackExec.qll

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ private class RatpackExecModel extends SummaryModelCsv {
5959
/** A reference type that extends a parameterization the Promise type. */
6060
private class RatpackPromise extends RefType {
6161
RatpackPromise() {
62-
getSourceDeclaration().getASourceSupertype*().hasQualifiedName("ratpack.exec", "Promise")
62+
this.getSourceDeclaration().getASourceSupertype*().hasQualifiedName("ratpack.exec", "Promise")
6363
}
6464
}
6565

@@ -68,13 +68,12 @@ private class RatpackPromise extends RefType {
6868
*/
6969
private class RatpackPromiseFluentMethod extends FluentMethod {
7070
RatpackPromiseFluentMethod() {
71-
getDeclaringType() instanceof RatpackPromise and
72-
not isStatic() and
71+
not this.isStatic() and
7372
// It's generally safe to assume that if the return type exactly matches the declaring type, `this` will be returned.
7473
exists(ParameterizedType t |
7574
t instanceof RatpackPromise and
76-
t = getDeclaringType() and
77-
t = getReturnType()
75+
t = this.getDeclaringType() and
76+
t = this.getReturnType()
7877
)
7978
}
8079
}

0 commit comments

Comments
 (0)