Review main Merged

64042[TASK] Migrate checkPidArray into PageRepository

Benni Mack CR +2 V +2 Normal +47 −78 updated 04/12/20, 12:32

Commit message

The code in cObj->checkPidArray() and cObj->checkPid() is checking
for valid page records, which semantically belongs to PageRepository.

As this code is now added to PageRepository, it is built in a more
flexible way now, and available for all core relevant parts, not
just Frontend logic.

The method cObj->checkPid(), previously marked as internal, is removed.

Review

  • Code review CR +2 Done
    • Anja Leichsenring +2
    • Daniel Goerz +1
    • Oli Bartsch +1
    • Georg Ringer +1
  • Verified V +2 Done
    • Anja Leichsenring +2
    • Georg Ringer +1
    • TYPO3com +1 CI

Issues 1

Files 3

Review log 1420

  1. Benni Mack uploaded patch set 1 04/01/20, 18:09

  2. TYPO3com voted on patch set 1 V +1 04/01/20, 18:20 Completed build in 10m 58s on Wed, 1 Apr, 06:20 PM Test Summary: 73050 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2062

  3. Benni Mack updated the commit message in patch set 2 04/02/20, 10:13

  4. TYPO3com voted on patch set 2 V -1 04/02/20, 10:30 Completed build in 16m 14s on Thu, 2 Apr, 10:30 AM Test Summary: 10 of 73744 failed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2087

  5. TYPO3com voted on patch set 2 V +1 04/02/20, 18:38 Completed build in 8h 41m 19s on Thu, 2 Apr, 06:38 PM Test Summary: 73258 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2087

  6. Oli Bartsch commented on patch set 2 04/04/20, 12:28

    PageRepository.php:1128 Unresolved

    return type - array - should be added.

    PageRepository.php:1130 Unresolved

    This check is not needed as we have $pageIds type hinted to be an array. We can simply check with : $pageIds === []
  7. Benni Mack uploaded patch set 3 04/04/20, 20:50

  8. TYPO3com voted on patch set 3 V -1 04/04/20, 21:13 Completed build in 22m 42s on Sat, 4 Apr, 09:12 PM Test Summary: 72823 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2179

  9. Oliver Klee commented on patch set 3 04/04/20, 21:22

    PageRepository.php:1124 Unresolved

    Would this be int[]?

    PageRepository.php:1126 Unresolved

    Should this be int[] as well?
  10. Oli Bartsch voted on patch set 3 CR +1 04/04/20, 21:29

  11. Benni Mack commented on patch set 4 04/04/20, 21:31

    Published edit on patch set 3.
  12. TYPO3com voted on patch set 4 V -1 04/04/20, 21:44 Completed build in 13m 12s on Sat, 4 Apr, 09:44 PM Test Summary: 73328 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2181

  13. TYPO3com voted on patch set 4 V +1 04/05/20, 19:43 Completed build in 22h 25m 24s on Sun, 5 Apr, 07:43 PM Test Summary: 73336 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-2181

  14. Georg Ringer commented on patch set 4 V +1 CR +1 04/06/20, 06:00

    PageRepository.php:1132

    should we use !empty now?
  15. Benni Mack commented on patch set 4 04/06/20, 06:24

    PageRepository.php:1132 Reply

    LOL. The previous comment suggested === [] as it was !empty(). I personally do not care, but would like to avoid multiple patchset on this side-topic. @Oli Klee - maybe you want to take a final decision here?
  16. Oliver Klee commented on patch set 4 04/06/20, 08:48

    PageRepository.php:1132 Reply

    I recommend checking for [] as it is more strict than empty().
  17. Oli Bartsch commented on patch set 4 CR +1 04/06/20, 11:30

    PageRepository.php:1132 Reply Unresolved

    +1 for strict checking. empty() is this kind of magic function which I personally try to avoid as much as possible. strict checking is easier to understand/read as it directly shows the expected value.
  18. Daniel Goerz voted on patch set 4 CR +1 04/08/20, 20:17

  19. Anja Leichsenring voted on patch set 4 V +2 CR +2 04/12/20, 12:32

  20. Anja Leichsenring merged patch set 5 04/12/20, 12:32