Add missing parameter based on parent class method
class A
{
public function execute($foo)
{
}
}
class B extends A{
- public function execute()
+ public function execute($foo)
{
}
}
Configure your rector.php
:
<?php
use Rector\Config\RectorConfig;
use Rector\Php80\Rector\ClassMethod\AddParamBasedOnParentClassMethodRector;
return RectorConfig::configure()
->withRules([
AddParamBasedOnParentClassMethodRector::class,
]);