69712[TASK] Unify autoSizeMax logic
Commit message
Review
-
Code review CR +2 Done
- Benni Mack +2
- Christian Kuhn +1
-
Verified V +2 Done
- Benni Mack +2
- Christian Kuhn +1
- core-ci +1 CI
Issues 1
Files 4
Review log 1420
-
Nikita Hovratov uploaded patch set 1 07/03/21, 16:15
-
core-ci voted on patch set 1 V -1 07/03/21, 16:28 Core CI is not happy: https://gitlab.typo3.org/TYPO3/CI/cms/-/pipelines/12943
-
Nikita Hovratov rebased onto patch set 2 07/03/21, 18:20
-
core-ci voted on patch set 2 V +1 07/03/21, 18:32 Core CI is happy: https://gitlab.typo3.org/TYPO3/CI/cms/-/pipelines/12944
-
Christian Kuhn commented on patch set 2 07/11/21, 10:57
Not sure if that's really worth the effort: These couple of lines don't harm to have at the couple of places we need it, a slight violation of DRY is imho ok. It's not that the according code is logically complex or similar, imho not worth to model-away. Also, according to our casual 'what is a utility' rules, a utility should be static, so if you want an object, it should be a service, or made static. I tend to not go through this refactoring and drop this approach. What do you think? -
Nikita Hovratov commented on patch set 2 07/12/21, 11:37
Reply
Ok, I just though 5 different places are enough for DRY rule to apply even if the logic is not too complex. My problem was mainly the slightly different approaches every place went through. Extracting it into a class seemed natural and added the opportunity to test the code more easily. If you are completely against a new class my compromise would be to at least unify the code at these various places to have real WET code. -
Christian Kuhn commented on patch set 2 08/08/21, 15:29
Reply
Yeah. I'm not too fond of having a utility class for these couple of lines. If you really want to abstract this, maybe inline it as helper method to one of the abstracts? Could be unit tested this way, too ;) Otherwise, align the different variants if you like and keep WET. -
Nikita Hovratov uploaded patch set 3 08/08/21, 16:10
-
Nikita Hovratov uploaded patch set 4 08/08/21, 16:15
-
core-ci voted on patch set 3 V +1 08/08/21, 16:21 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/14283
-
core-ci voted on patch set 4 V +1 08/08/21, 16:26 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/14284
-
Nikita Hovratov rebased onto patch set 5 08/16/21, 17:28
-
core-ci voted on patch set 5 V +1 08/16/21, 17:55 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15203
-
Benni Mack commented on patch set 5 09/30/21, 14:52
care to rebase? -
Nikita Hovratov uploaded patch set 6 09/30/21, 15:08
-
core-ci voted on patch set 6 V +1 09/30/21, 15:24 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/17355
-
Benni Mack voted on patch set 6 CR +1 10/01/21, 13:35
-
Christian Kuhn commented on patch set 6 V +1 CR +1 10/07/21, 14:32
looks good to me, couldn't find an issue with proposed solution. -
Benni Mack voted on patch set 6 V +2 CR +2 10/08/21, 07:48
-
Benni Mack merged patch set 7 10/08/21, 07:48