check method
Implementation
@override
void check(
DcqRegistry registry,
) {
registry.addMethodInvocation((node) {
if (node.methodName.name != 'completeError') return;
final args = node.argumentList.arguments;
if (args.length >= 2) return;
final target = node.target;
if (target == null) return;
final targetType = target.staticType;
if (targetType is! InterfaceType) return;
if (targetType.element.name != 'Completer') return;
reportAtNode(node);
});
}