check method
Implementation
@override
void check(
DcqRegistry registry,
) {
registry.addMethodInvocation((node) {
if (node.methodName.name != 'substring') return;
final target = node.target;
if (target == null) return;
final targetType = target.staticType;
if (targetType is InterfaceType && targetType.element.name == 'String') {
reportAtNode(node);
}
});
}