Skip to content

Commit ac48eca

Browse files
committed
Python: Use cls.getMethod instead of getName
1 parent 93e3566 commit ac48eca

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

python/ql/lib/semmle/python/dataflow/new/internal/DataFlowDispatch.qll

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2145,8 +2145,7 @@ module DuckTyping {
21452145
exists(Class cls |
21462146
f.getScope() = cls and
21472147
superclass = getADirectSuperclass+(cls) and
2148-
overridden = superclass.getAMethod() and
2149-
overridden.getName() = f.getName()
2148+
overridden = superclass.getMethod(f.getName())
21502149
)
21512150
}
21522151

0 commit comments

Comments
 (0)