diff --git a/src/Rector/Class_/PreferPHPUnitSelfCallRector.php b/src/Rector/Class_/PreferPHPUnitSelfCallRector.php index aef04be7..80212584 100644 --- a/src/Rector/Class_/PreferPHPUnitSelfCallRector.php +++ b/src/Rector/Class_/PreferPHPUnitSelfCallRector.php @@ -91,7 +91,7 @@ public function refactor(Node $node): ?Node return null; } - if (! $this->nodeNameResolver->startsWith($node->name, 'assert')) { + if (! str_starts_with($methodName, 'assert')) { return null; }