Closed neveldo closed 2 years ago
I think code on page 97 could be improved:
Why?
This is not really a mistake I guess, but in the code snippet from this page, you use $rectorConfig->services()->set() to load a rule whereas $rectorConfig->rule() is used everywhere else in the book.
$rectorConfig->services()->set()
$rectorConfig->rule()
I propose this change
- $rectorConfig->services() - ->set(CaptureReturnValueRector::class); + $rectorConfig->rule(CaptureReturnValueRector::class);
Thanks!
This should be gone by next release :+1:
Code Improvement
I think code on page 97 could be improved:
Why?
This is not really a mistake I guess, but in the code snippet from this page, you use
$rectorConfig->services()->set()
to load a rule whereas$rectorConfig->rule()
is used everywhere else in the book.I propose this change
Thanks!