[BUGFIX] Use default page id for fetching a site in SlugService
The rebuildSlugsForSlugChange function of SlugService updates slugs of sub pages and also creates redirects for them, after changing the slug of their parent page. This process requires to fetch the corresponding site configuration. In cases like changing the slug of a localized root page this throws a SiteNotFoundException, because the site is always mapped to the default page id which can not be determined for localized root pages because their pid is 0. It's therefore necessary to always use the default page id for fetching the site through SiteFinder. Resolves: #92733 Releases: master, 10.4 Change-Id: I8b41647d63d444982b2d2d6f209dea4278034488 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/66353 Tested-by:TYPO3com <noreply@typo3.com> Tested-by:
Benni Mack <benni@typo3.org> Tested-by:
Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Andreas Fernandez <a.fernandez@scripting-base.de>
Showing
- typo3/sysext/redirects/Classes/Service/SlugService.php 2 additions, 1 deletiontypo3/sysext/redirects/Classes/Service/SlugService.php
- typo3/sysext/redirects/Tests/Functional/Service/Fixtures/SlugServiceTest_pages_test4.xml 63 additions, 0 deletions...nctional/Service/Fixtures/SlugServiceTest_pages_test4.xml
- typo3/sysext/redirects/Tests/Functional/Service/SlugServiceTest.php 37 additions, 0 deletions...xt/redirects/Tests/Functional/Service/SlugServiceTest.php
Please register or sign in to comment