Review 12.4 Merged

86313[BUGFIX] Properly evaluate EXT:indexed_search restriction by mediaType

Garvin Hicking CR +2 V +2 Normal +104 −2 updated 10/15/24, 05:20

Commit message

With refactorings in #102898 and #97412 the IndexSearchRepository
class property $mediaType was changed from a mixed type to
an integer, and later only integers were mapped to ENUM backed
values.

However, mediaType could always be not only an integer in range
of -2, -1 and 0 but also a string with a common file extension
like 'ppt' and so on.

This patch now allows both types (string and enum from int)
for proper search evaluation.

A functional test has been added to verify behaviour.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Stefan Bürk +1
  • Verified V +2 Done
    • Benni Mack +2
    • core-ci +1 CI

Issues 3

Files 2

Review log 1015

  1. Garvin Hicking commented on patch set 1 09/24/24, 18:58

    Cherry Picked from branch main. The following files contain Git conflicts: * typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php * typo3/sysext/indexed_search/Tests/Functional/IndexSearchRepositoryTest.php
  2. core-ci voted on patch set 1 V -1 09/24/24, 19:02 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66514

  3. Garvin Hicking uploaded patch set 2 V -1 09/24/24, 19:07

    Address merge conflict
  4. Garvin Hicking commented on patch set 2 09/24/24, 19:08

    Backport note: Several differences due to not being an ENUM in v12. Also slight functional difference because values like "-189" and "189" are passed through, only in v13 the ENUM restricts this. But it's escaped like a file extension, should not matter.
  5. core-ci voted on patch set 2 V +1 09/24/24, 19:13 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66516

  6. Garvin Hicking uploaded patch set 3 V +1 09/25/24, 07:36

    backport code review
  7. core-ci voted on patch set 3 V -1 09/25/24, 07:45 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66545

  8. Garvin Hicking uploaded patch set 4 V -1 09/25/24, 09:23

    CGL
  9. core-ci voted on patch set 4 V +1 09/25/24, 09:29 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66562

  10. Garvin Hicking uploaded patch set 5 V +1 09/30/24, 10:13

    Use different testing approach
  11. core-ci voted on patch set 5 V +1 09/30/24, 10:18 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/66850

  12. Garvin Hicking marked it ready for review 10/11/24, 07:13

  13. Stefan Bürk voted on patch set 5 CR +1 10/14/24, 08:24

  14. Benni Mack commented on patch set 5 CR +2 V +2 10/15/24, 05:20

    Reply

    Acknowledged
  15. Benni Mack merged patch set 6 10/15/24, 05:20