Find the best Rector rule to solve your problem
Turns defined function call new one.
-view("...", []);
+Laravel\Templating\render("...", []);
Remove & from function and method calls
final class SomeClass
{
public function run($one)
{
- return strlen(&$one);
+ return strlen($one);
}
}
Remove 0 from break and continue
class SomeClass
{
public function run($random)
{
- continue 0;
- break 0;
+ continue;
+ break;
$five = 5;
- continue $five;
+ continue 5;
- break $random;
+ break;
}
}
Long array to short array
class SomeClass
{
public function run()
{
- return array();
+ return [];
}
}