Skip to content

Commit 7f6067d

Browse files
GeekMasherowen-mc
andauthored
Update go/ql/lib/semmle/go/frameworks/GoMicro.qll
Co-authored-by: Owen Mansel-Chan <[email protected]>
1 parent cefb914 commit 7f6067d

File tree

1 file changed

+3
-6
lines changed

1 file changed

+3
-6
lines changed

go/ql/lib/semmle/go/frameworks/GoMicro.qll

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -75,12 +75,9 @@ module GoMicro {
7575
*/
7676
class ServiceServerType extends NamedType {
7777
ServiceServerType() {
78-
exists(ServiceInterfaceType i, TypeEntity te |
79-
this.implements(i) and
80-
this.getName().regexpMatch("(?i).*Handler") and
81-
te.getType() = this and
82-
te.getDeclaration().getLocation().getFile() instanceof ProtocGeneratedFile
83-
)
78+
this.implements(any(ServiceInterfaceType i)) and
79+
this.getName().regexpMatch("(?i).*Handler") and
80+
this.hasLocationInfo(any(ProtocGeneratedFile f).getAbsolutePath(), _, _, _, _)
8481
}
8582
}
8683

0 commit comments

Comments
 (0)