Add extra space before new assign set
final class SomeClass
{
public function run()
{
$value = new Value;
$value->setValue(5);
+
$value2 = new Value;
$value2->setValue(1);
}
}
Configure your rector.php
:
<?php
use Rector\CodingStyle\Rector\ClassMethod\NewlineBeforeNewAssignSetRector;
use Rector\Config\RectorConfig;
return RectorConfig::configure()
->withRules([
NewlineBeforeNewAssignSetRector::class,
]);