Skip to content

Commit

Permalink
Rectify (#5226)
Browse files Browse the repository at this point in the history
* Rectify

* [ci-review] Rector Rectify

---------

Co-authored-by: GitHub Action <actions@github.com>
  • Loading branch information
samsonasik and actions-user committed Nov 6, 2023
1 parent 7607b33 commit 6d80745
Showing 1 changed file with 1 addition and 12 deletions.
13 changes: 1 addition & 12 deletions rules/CodingStyle/Rector/If_/NullableCompareToNullRector.php
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,6 @@
use PhpParser\Node\Expr\BinaryOp\NotIdentical;
use PhpParser\Node\Expr\BooleanNot;
use PhpParser\Node\Stmt\If_;
use PHPStan\Type\BooleanType;
use PHPStan\Type\FloatType;
use PHPStan\Type\IntegerType;
use PHPStan\Type\MixedType;
use PHPStan\Type\NullType;
use PHPStan\Type\StringType;
use PHPStan\Type\TypeCombinator;
use PHPStan\Type\UnionType;
use Rector\Core\Rector\AbstractRector;
Expand Down Expand Up @@ -104,11 +98,6 @@ private function isNullableNonScalarType(Expr $expr): bool
}

$nativeType = TypeCombinator::removeNull($nativeType);

if ($nativeType->isScalar()->yes()) {
return false;
}

return true;
return !$nativeType->isScalar()->yes();
}
}

0 comments on commit 6d80745

Please sign in to comment.