75795[TASK] Avoid getIndpEnv and TYPO3_REQUEST in Link Builder
Commit message
Review
-
Code review CR +2 Done
- Benni Mack +2
- Christian Kuhn +1
- Andreas Kienast +1
-
Verified V +2 Done
- Benni Mack +2
- Christian Kuhn +1
- Andreas Kienast +1
- core-ci +1 CI
Issues 1
Files 6
- typo3/sysext/frontend/Classes/Controller/ErrorController.php3+6 −4
- typo3/sysext/frontend/Classes/Typolink/AbstractTypolinkBuilder.php4+11 −6
- typo3/sysext/frontend/Tests/Functional/ContentObject/ContentObjectRendererTest.php+19 −19
- typo3/sysext/frontend/Tests/Functional/SiteHandling/SlugSiteRequestTest.php+1 −0
- typo3/sysext/frontend/Tests/Unit/Controller/ErrorControllerTest.php+40 −15
- typo3/sysext/frontend/Tests/Unit/Typolink/AbstractTypolinkBuilderTest.php+37 −17
Review log 1623
-
Benni Mack uploaded patch set 1 09/20/22, 10:45
-
Benni Mack updated the commit message in patch set 2 09/20/22, 10:46
-
core-ci voted on patch set 2 V -1 09/20/22, 11:04 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31310
-
core-ci voted on patch set 1 V -1 09/20/22, 11:05 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31309
-
Benni Mack uploaded patch set 3 09/20/22, 12:46
-
Benni Mack uploaded patch set 4 09/20/22, 12:49
-
core-ci voted on patch set 4 V -1 09/20/22, 12:58 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31320
-
core-ci voted on patch set 3 V -1 09/20/22, 12:59 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31319
-
Benni Mack uploaded patch set 5 09/20/22, 14:15
-
core-ci voted on patch set 5 V +1 09/20/22, 14:27 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31321
-
Christian Kuhn commented on patch set 5 CR -1 09/21/22, 09:14
-1 for now to get the two comments answeredd.ErrorController.php:139why the fallback to createFromRequest? the normalizedParams middleware is very early in the middleware chain. i'd rather getAttribute() and throw an exception if the attribute does not exist?AbstractTypolinkBuilder.php:85same here as in the other file - i'd say we should expect the attribute is set, and throw an exception if not. -
Benni Mack commented on patch set 5 09/21/22, 10:01
ErrorController.php:139ReplyThis one can rather go away, I agree.AbstractTypolinkBuilder.php:85Replytypolink also "could" made work in an CLI environment, where somebody did not create a full request with normalized params. Instead of having all callers do this on CLI, I suggest to use it the way as I did it. You can see in the tests, that you do not have to populate the normalizedParams. Bottom line: It's more convenient. -
Christian Kuhn commented on patch set 5 09/21/22, 10:40
AbstractTypolinkBuilder.php:85Replyok. however, we should think about making typo3_request mandatory in typolink / link generation in general, even in cli: typolink *has* a dependency to request and we should make this explicit and force cli to set up a proper request if it generates links (or call a FE application) ... but that's a story for a different patch. we could however add an @todo now that this implicit normalized_params generation should fall at some point. -
Christian Kuhn uploaded patch set 6 09/21/22, 11:55
-
Christian Kuhn commented on patch set 6 09/21/22, 11:55
ErrorController.php:139ReplyDoneAbstractTypolinkBuilder.php:85ReplyDone -
core-ci voted on patch set 6 V -1 09/21/22, 12:04 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31355
-
Christian Kuhn commented on patch set 6 CR -1 09/21/22, 12:18
will greenify -
Christian Kuhn uploaded patch set 7 09/21/22, 12:42
-
core-ci voted on patch set 7 V +1 09/21/22, 12:49 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/31364
-
Christian Kuhn voted on patch set 7 V +1 CR +1 09/21/22, 12:54
-
Andreas Kienast voted on patch set 7 V +1 CR +1 09/21/22, 13:03
-
Benni Mack voted on patch set 7 V +2 CR +2 09/21/22, 13:07
-
Benni Mack merged patch set 8 09/21/22, 13:08