Review main Merged

96706[TASK] Warn when saving a shadowed redirect

Oli Bartsch CR +2 V +2 Hard +333 −5 updated 10/22/26, 20:00

Commit message

The shadowed integrity status of redirects was only updated by the
redirects:checkintegrity command, so editors creating a redirect
with an already used source got no feedback.

When a redirect is created, changed or deleted, the shadowed status
of all redirects sharing its source host is now updated directly.
If the saved redirect is shadowed by another one or shadows another
one, a warning is shown. Saving is not prevented, since shadowed
redirects may be intended.

Review

  • Code review CR +2 Done
    • Oli Bartsch +2
    • Garvin Hicking +1
  • Verified V +2 Done
    • Oli Bartsch +2
    • Garvin Hicking +1
    • core-ci +1 CI

Issues 3

Files 6

Review log 1215

  1. Oli Bartsch uploaded patch set 1 10/15/26, 07:27

  2. core-ci voted on patch set 1 V +1 10/15/26, 07:35 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111167

  3. Oli Bartsch rebased onto patch set 2 V +1 10/16/26, 15:39

  4. core-ci voted on patch set 2 V +1 10/16/26, 15:48 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111377

  5. Oliver Klee voted on patch set 2 V +1 10/17/26, 17:09

  6. Oli Bartsch wrote 10/19/26, 07:19

    Topic set to community-sprint
  7. Guido Schmechel commented on patch set 2 10/19/26, 12:23

    DataHandlerShadowedRedirectHook.php:109

    Just to make sure I understand: Is there a reason why the RedirectRepository isn't being used here? Is it because this function only used in one place? The feature is pretty general, so maybe it would make sense there?
  8. Garvin Hicking commented on patch set 2 10/19/26, 14:47

    Important-111073-SavingAShadowedRedirectShowsAWarning.rst:3

    I don't think we need this RST
  9. Oli Bartsch uploaded patch set 3 V +1 10/19/26, 16:17

  10. Oli Bartsch commented on patch set 3 10/19/26, 16:17

    Important-111073-SavingAShadowedRedirectShowsAWarning.rst:3 Reply

    Done

    DataHandlerShadowedRedirectHook.php:109 Reply

    The lookup intentionally runs without any restrictions: after a delete command the record is already deleted=1, and hidden/timed redirects take part in shadowing as well. RedirectRepository is tailored to the backend module, so an unrestricted method there would be the odd one out and easy to misuse in a permission-relevant context.
  11. core-ci voted on patch set 3 V +1 10/19/26, 16:26 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111675

  12. Guido Schmechel commented on patch set 3 10/19/26, 20:02

    DataHandlerShadowedRedirectHook.php:109 Reply

    Okay, I understand. Thanks for the explanation :-)
  13. Garvin Hicking voted on patch set 3 CR +1 V +1 10/19/26, 21:03

  14. Oli Bartsch voted on patch set 3 CR +2 V +2 10/22/26, 20:00

  15. Oli Bartsch merged patch set 4 10/22/26, 20:00