|
5 | 5 | use Rector\CodeQuality\Rector\BooleanAnd\SimplifyEmptyArrayCheckRector; |
6 | 6 | use Rector\CodeQuality\Rector\Class_\CompleteDynamicPropertiesRector; |
7 | 7 | use Rector\CodeQuality\Rector\Expression\InlineIfToExplicitIfRector; |
8 | | -use Rector\CodeQuality\Rector\For_\ForToForeachRector; |
9 | 8 | use Rector\CodeQuality\Rector\Foreach_\UnusedForeachValueToArrayKeysRector; |
10 | | -use Rector\CodeQuality\Rector\FuncCall\AddPregQuoteDelimiterRector; |
11 | 9 | use Rector\CodeQuality\Rector\FuncCall\ChangeArrayPushToArrayAssignRector; |
12 | 10 | use Rector\CodeQuality\Rector\FuncCall\SimplifyRegexPatternRector; |
13 | 11 | use Rector\CodeQuality\Rector\FuncCall\SimplifyStrposLowerRector; |
|
24 | 22 | use Rector\Core\ValueObject\PhpVersion; |
25 | 23 | use Rector\DeadCode\Rector\ClassMethod\RemoveUnusedPromotedPropertyRector; |
26 | 24 | use Rector\DeadCode\Rector\If_\UnwrapFutureCompatibleIfPhpVersionRector; |
27 | | -use Rector\DeadCode\Rector\MethodCall\RemoveEmptyMethodCallRector; |
28 | 25 | use Rector\DeadCode\Rector\Property\RemoveUnusedPrivatePropertyRector; |
29 | 26 | use Rector\DeadCode\Rector\StmtsAwareInterface\RemoveJustPropertyFetchForAssignRector; |
30 | 27 | use Rector\EarlyReturn\Rector\Foreach_\ChangeNestedForeachIfsToEarlyContinueRector; |
31 | 28 | use Rector\EarlyReturn\Rector\If_\ChangeIfElseValueAssignToEarlyReturnRector; |
32 | 29 | use Rector\EarlyReturn\Rector\If_\RemoveAlwaysElseRector; |
33 | 30 | use Rector\EarlyReturn\Rector\Return_\PreparedValueToEarlyReturnRector; |
34 | 31 | use Rector\Php55\Rector\String_\StringClassNameToClassConstantRector; |
35 | | -use Rector\Php56\Rector\FunctionLike\AddDefaultValueForUndefinedVariableRector; |
36 | 32 | use Rector\Php73\Rector\FuncCall\JsonThrowOnErrorRector; |
37 | 33 | use Rector\Php73\Rector\FuncCall\StringifyStrNeedlesRector; |
38 | | -use Rector\PHPUnit\Rector\Class_\AnnotationWithValueToAttributeRector; |
| 34 | +use Rector\PHPUnit\AnnotationsToAttributes\Rector\Class_\AnnotationWithValueToAttributeRector; |
39 | 35 | use Rector\PHPUnit\Set\PHPUnitSetList; |
40 | 36 | use Rector\Privatization\Rector\Property\PrivatizeFinalClassPropertyRector; |
41 | | -use Rector\PSR4\Rector\FileWithoutNamespace\NormalizeNamespaceByPSR4ComposerAutoloadRector; |
42 | 37 | use Rector\Set\ValueObject\LevelSetList; |
43 | 38 | use Rector\Set\ValueObject\SetList; |
44 | 39 |
|
|
89 | 84 | RemoveUnusedPromotedPropertyRector::class, |
90 | 85 | AnnotationWithValueToAttributeRector::class, |
91 | 86 |
|
92 | | - // Ignore tests that might make calls without a result |
93 | | - RemoveEmptyMethodCallRector::class => [ |
94 | | - __DIR__ . '/tests', |
95 | | - ], |
96 | | - |
97 | | - // Ignore files that should not be namespaced to their folder |
98 | | - NormalizeNamespaceByPSR4ComposerAutoloadRector::class => [ |
99 | | - __DIR__ . '/src/Helpers', |
100 | | - __DIR__ . '/src/Language', |
101 | | - __DIR__ . '/tests/_support', |
102 | | - ], |
103 | | - |
104 | 87 | // May load view files directly when detecting classes |
105 | 88 | StringClassNameToClassConstantRector::class, |
106 | 89 |
|
107 | | - // May be uninitialized on purpose |
108 | | - AddDefaultValueForUndefinedVariableRector::class, |
109 | | - |
110 | 90 | // See https://github.com/codeigniter4/shield/issues/228 |
111 | 91 | RemoveJustPropertyFetchForAssignRector::class => [ |
112 | 92 | __DIR__ . '/src/Models/UserModel.php', |
|
130 | 110 | $rectorConfig->rule(SimplifyUselessVariableRector::class); |
131 | 111 | $rectorConfig->rule(RemoveAlwaysElseRector::class); |
132 | 112 | $rectorConfig->rule(CountArrayToEmptyArrayComparisonRector::class); |
133 | | - $rectorConfig->rule(ForToForeachRector::class); |
134 | 113 | $rectorConfig->rule(ChangeNestedForeachIfsToEarlyContinueRector::class); |
135 | 114 | $rectorConfig->rule(ChangeIfElseValueAssignToEarlyReturnRector::class); |
136 | 115 | $rectorConfig->rule(SimplifyStrposLowerRector::class); |
|
143 | 122 | $rectorConfig->rule(UnusedForeachValueToArrayKeysRector::class); |
144 | 123 | $rectorConfig->rule(ChangeArrayPushToArrayAssignRector::class); |
145 | 124 | $rectorConfig->rule(UnnecessaryTernaryExpressionRector::class); |
146 | | - $rectorConfig->rule(AddPregQuoteDelimiterRector::class); |
147 | 125 | $rectorConfig->rule(SimplifyRegexPatternRector::class); |
148 | 126 | $rectorConfig->rule(FuncGetArgsToVariadicParamRector::class); |
149 | 127 | $rectorConfig->rule(MakeInheritedMethodVisibilitySameAsParentRector::class); |
150 | 128 | $rectorConfig->rule(SimplifyEmptyArrayCheckRector::class); |
151 | | - $rectorConfig->rule(NormalizeNamespaceByPSR4ComposerAutoloadRector::class); |
152 | 129 | $rectorConfig->rule(StringClassNameToClassConstantRector::class); |
153 | 130 | $rectorConfig->rule(PrivatizeFinalClassPropertyRector::class); |
154 | 131 | $rectorConfig->rule(CompleteDynamicPropertiesRector::class); |
|
0 commit comments