File tree Expand file tree Collapse file tree 3 files changed +11
-6
lines changed
Expand file tree Collapse file tree 3 files changed +11
-6
lines changed Original file line number Diff line number Diff line change 1919 php-version : [
2020 ' 8.2' ,
2121 ' 8.3' ,
22+ ' 8.4'
2223 ]
2324
2425 steps :
Original file line number Diff line number Diff line change 1313 __DIR__ . '/src ' ,
1414 __DIR__ . '/tests ' ,
1515 ])
16+ ->withRules ([
17+ \Rector \Php84 \Rector \Param \ExplicitNullableParamTypeRector::class,
18+ ])
1619 ->withSets ([
1720 JMSSetList::ANNOTATIONS_TO_ATTRIBUTES ,
18- PHPUnitSetList::PHPUNIT_100 ,
21+ PHPUnitSetList::PHPUNIT_110 ,
1922 PHPUnitSetList::PHPUNIT_CODE_QUALITY ,
2023 PHPUnitSetList::ANNOTATIONS_TO_ATTRIBUTES ,
2124 SetList::TYPE_DECLARATION ,
2225 SetList::CODE_QUALITY ,
2326 SetList::CODING_STYLE ,
2427 SetList::DEAD_CODE ,
25- SetList:: PHP_82 ,
28+ \ Rector \ Set \ ValueObject \LevelSetList:: UP_TO_PHP_84 ,
2629 SetList::PRIVATIZATION ,
2730 SetList::EARLY_RETURN ,
2831 SetList::INSTANCEOF ,
3336 \Rector \DeadCode \Rector \ClassMethod \RemoveUnusedPromotedPropertyRector::class,
3437 //allow to use promoted properties that only purpose is to get serialized
3538 \Rector \DeadCode \Rector \ClassMethod \RemoveEmptyClassMethodRector::class,
36- //this is stupid and makes code unreadable
39+ //this makes code unreadable
3740 \Rector \Strict \Rector \Ternary \BooleanInTernaryOperatorRuleFixerRector::class,
38- \Rector \Strict \Rector \BooleanNot \BooleanInBooleanNotRuleFixerRector::class
41+ \Rector \Strict \Rector \BooleanNot \BooleanInBooleanNotRuleFixerRector::class,
42+ \Rector \Php81 \Rector \Property \ReadOnlyPropertyRector::class,
3943 ])
4044 ->withFileExtensions (['php ' ])
4145 ->withCache (
Original file line number Diff line number Diff line change 1010class Tax
1111{
1212 #[Serializer \SerializedName('Money ' )]
13- private Money $ money ;
13+ private readonly Money $ money ;
1414
1515 /**
1616 * @var TaxDetail[]
@@ -24,7 +24,7 @@ public function __construct(
2424 int $ value ,
2525 #[Serializer \SerializedName('Description ' )]
2626 #[Serializer \XmlElement(cdata: false )]
27- private MultilanguageString $ description ,
27+ private readonly MultilanguageString $ description ,
2828 ) {
2929 $ this ->money = new Money ($ currency , $ value );
3030 }
You can’t perform that action at this time.
0 commit comments