Remove class method that only delegates call to parent class method with the same values
class SomeCommand extends Command
{
- protected function configure(): void
- {
- parent::configure();
- }
}
Configure your rector.php:
<?php
use Rector\Config\RectorConfig;
use Rector\DeadCode\Rector\ClassMethod\RemoveParentDelegatingClassMethodRector;
return RectorConfig::configure()
->withRules([
RemoveParentDelegatingClassMethodRector::class,
]);