Bug #99156
closedAllow rendering empty language menu if sys_language_uid 0 is disabled in PHP 8.1
100%
Description
On all sites we have a default language menu rendered via the LanguageMenuProcessor.
The typical language config is
0 = de 1 = en
However we have one sites with primary language `en`. However in order to aggregate content and link between sites with a correct url this site has the config
0 = en (disabled) 1 = en
With PHP 8.1 instead of an empty LanuageMenu as output, an exception is thrown:
PHP Warning: Trying to access array offset on value of type null in /typo3/sysext/frontend/Classes/DataProcessing/LanguageMenuProcessor.php line 493
Updated by Gerrit Code Review about 2 years ago
- Status changed from New to Under Review
Patch set 1 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/76760
Updated by Gerrit Code Review about 2 years ago
Patch set 1 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/76761
Updated by J. Peter M. Schuler about 2 years ago
It is available at
https://review.typo3.org/c/Packages/TYPO3.CMS/+/76760
Abandoned 76760 because by error I created two, one broken (76760) and another good one, which I kept: https://review.typo3.org/c/Packages/TYPO3.CMS/+/76761
Updated by J. Peter M. Schuler about 2 years ago
While the patch solves the problem with the exception. The result is still that the pages in that scenario are only displayed to logged in editors, while a public access results in 404. This points to a more complex problem with that site config as a regression from using PHP 8.1. However probably this should be tackled separately.
Updated by Gerrit Code Review about 2 years ago
Patch set 2 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/76761
Updated by Gerrit Code Review almost 2 years ago
Patch set 3 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/76761
Updated by Gerrit Code Review almost 2 years ago
Patch set 1 for branch 11.5 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/76779
Updated by J. Peter M. Schuler almost 2 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 38ab87f4f3418b9a95930703e6dc0e227b9013a9.