Review main Merged Breaking

77682[!!!][FEATURE] Always allow listeners to manipulate the canonical URL

Bastien Lutz CR +2 V +2 Normal +184 −33 updated 01/24/24, 23:21

Commit message

The ModifyUrlForCanonicalTagEvent is now always dispatched at the
end of the generation process, just before the tag is being built.

This way, listeners are now able to fully influence the generation
of the canonical URL, after the standard functionality, e.g.
fetching the URL from page properties, has been executed.

Additionally, the Event is now also always dispatched, in case
the canonical tag generation is disabled via TypoScript or via
page properties. This information is then available using the
new getCanonicalGenerationDisabledException() method.

Review

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

Issues 1

Files 7

Review log 1319

  1. Bastien Lutz uploaded patch set 1 02/03/23, 14:56

  2. core-ci voted on patch set 1 V +1 02/03/23, 15:12 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/36991

  3. Benni Mack commented on patch set 1 CR -1 02/03/23, 17:00

    CanonicalGenerator.php:55

    with this change, when a page has "no_index", then the event is not called, thus it is not possible to override it anymore.
  4. Bastien Lutz commented on patch set 1 02/04/23, 22:30

    CanonicalGenerator.php:55 Reply

    Good point. How about renaming the existing event to something like setCanonicalTagUri and add a new event called modifyCanonicalTagUri after the generation of the canonical tag uri. This would solve the issue and allows to override it even if "no_index" is set.
  5. Benni Mack updated the commit message in patch set 2 CR -1 V +1 05/03/23, 09:52

  6. Benni Mack uploaded patch set 3 01/12/24, 15:07

  7. Benni Mack commented on patch set 3 01/12/24, 15:12

    moved the location, we now need a breaking RST

    CanonicalGenerator.php:55 Reply

    Done
  8. core-ci voted on patch set 3 V -1 01/12/24, 15:13 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/51512

  9. Oli Bartsch uploaded patch set 4 V -1 01/24/24, 14:24

  10. core-ci voted on patch set 4 V -1 01/24/24, 14:29 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/52083

  11. Oli Bartsch uploaded patch set 5 V -1 01/24/24, 14:31

  12. core-ci voted on patch set 5 V +1 01/24/24, 14:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/52084

  13. Oli Bartsch uploaded patch set 6 V +1 01/24/24, 15:52

  14. core-ci voted on patch set 6 V -1 01/24/24, 16:00 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/52094

  15. core-ci voted on patch set 6 V +1 01/24/24, 16:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/52094

  16. Benni Mack voted on patch set 6 CR +1 V +1 01/24/24, 16:41

  17. Stefan Bürk voted on patch set 6 CR +1 V +1 01/24/24, 23:13

  18. Oli Bartsch voted on patch set 6 CR +2 V +2 01/24/24, 23:21

  19. Oli Bartsch merged patch set 7 01/24/24, 23:21