Skip to content

Commit

Permalink
[BUGFIX] dont remove phpdoc tags with rector for backwards compat in …
Browse files Browse the repository at this point in the history
…the api generation process
  • Loading branch information
mgrundkoetter committed Jun 30, 2021
1 parent 95efdde commit 7ee29a9
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions build/config/rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,15 +3,19 @@
declare(strict_types=1);

use Rector\Core\Configuration\Option;
use Rector\Set\ValueObject\SetList;
use Rector\DeadCode\Rector\ClassConst\RemoveUnusedPrivateClassConstantRector;
use Rector\DeadCode\Rector\ClassMethod\RemoveUselessParamTagRector;
use Rector\DeadCode\Rector\ClassMethod\RemoveUselessReturnTagRector;
use Rector\Set\ValueObject\SetList;
use Symfony\Component\DependencyInjection\Loader\Configurator\ContainerConfigurator;

return static function (ContainerConfigurator $containerConfigurator): void {
$containerConfigurator->import(SetList::DEAD_CODE);

// this is removed as all the DTO object constants are not used inside the library itself
// get parameters
$parameters = $containerConfigurator->parameters();
$parameters->set(Option::SKIP, [RemoveUnusedPrivateClassConstantRector::class]);
$parameters->set(Option::SKIP, [
RemoveUnusedPrivateClassConstantRector::class,
RemoveUselessParamTagRector::class,
RemoveUselessReturnTagRector::class
]);
};

0 comments on commit 7ee29a9

Please sign in to comment.