Remove useless is_object() check on combine with instanceof check
-is_object($obj) && $obj instanceof DateTime
+$obj instanceof DateTime
Configure your rector.php
:
<?php
use Rector\CodeQuality\Rector\BooleanAnd\RemoveUselessIsObjectCheckRector;
use Rector\Config\RectorConfig;
return RectorConfig::configure()
->withRules([
RemoveUselessIsObjectCheckRector::class,
]);