Skip to content

Commit

Permalink
exclude finalize rule from private set, to keep safer
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasVotruba committed Jan 30, 2024
1 parent f680a07 commit c90d698
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 0 additions & 2 deletions config/set/privatization.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,12 @@
declare(strict_types=1);

use Rector\Config\RectorConfig;
use Rector\Privatization\Rector\Class_\FinalizeClassesWithoutChildrenRector;
use Rector\Privatization\Rector\ClassMethod\PrivatizeFinalClassMethodRector;
use Rector\Privatization\Rector\MethodCall\PrivatizeLocalGetterToPropertyRector;
use Rector\Privatization\Rector\Property\PrivatizeFinalClassPropertyRector;

return static function (RectorConfig $rectorConfig): void {
$rectorConfig->rules([
FinalizeClassesWithoutChildrenRector::class,
PrivatizeLocalGetterToPropertyRector::class,
PrivatizeFinalClassPropertyRector::class,
PrivatizeFinalClassMethodRector::class,
Expand Down
2 changes: 2 additions & 0 deletions utils/Command/MissingInSetCommand.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
use Rector\Contract\Rector\ConfigurableRectorInterface;
use Rector\DeadCode\Rector\ClassMethod\RemoveNullTagValueNodeRector;
use Rector\Php73\Rector\FuncCall\JsonThrowOnErrorRector;
use Rector\Privatization\Rector\Class_\FinalizeClassesWithoutChildrenRector;
use Rector\TypeDeclaration\Rector\BooleanAnd\BinaryOpNullableToInstanceofRector;
use Rector\TypeDeclaration\Rector\StmtsAwareInterface\DeclareStrictTypesRector;
use Rector\TypeDeclaration\Rector\While_\WhileNullableToInstanceofRector;
Expand Down Expand Up @@ -37,6 +38,7 @@ final class MissingInSetCommand extends Command
RemoveNullTagValueNodeRector::class,
// personal preference, enable on purpose
ArraySpreadInsteadOfArrayMergeRector::class,
FinalizeClassesWithoutChildrenRector::class,
];

public function __construct(
Expand Down

0 comments on commit c90d698

Please sign in to comment.