#110040StandardContentPreviewRenderer trimExplode needs a string, but is null
Description
Hi,
in the file vendor/typo3/cms-backend/Classes/Preview/StandardContentPreviewRenderer.php on line 217 there is an problem, which leads to an 503 Oops, an error occurred! The Error message in short is:
> TYPO3\CMS\Core\Utility\GeneralUtility::trimExplode(): Argument #2 ($string) must be of type string, null given, called in /html/myproject/vendor/typo3/cms-backend/Classes/Preview/StandardContentPreviewRenderer.php on line 217
The problem is in here:
case 'bullets':
$list = GeneralUtility::trimExplode(LF, $recordObj->get('bodytext'), true);
If a customer creates the content element “Bullet list” and forgot to fill out the content for the bullet list, the bodytext is null.
After that the Layout isn’t usable anymore.
Tested in v14.3.2
Reviews 2
Related issues 1
History 68
-
Steve Weise-Mertens changed target version 06/10/26, 11:10
-
Gerrit Code Review pushed patch set 1 for main to change 94471 status
NewUnder Review 06/10/26, 15:20 -
Garvin Hicking changed Related to #108733 06/10/26, 15:20
-
Garvin Hicking commented 06/10/26, 15:20
-
Steve Weise-Mertens commented 06/10/26, 16:22
Garvin Hicking wrote in #note-4:
> Thanks for the report! Maybe you can try out the patch and see if this solves it for you?The fix solves the problem. Thank you for your fast solution!
-
Gerrit Code Review pushed patch set 1 for 14.3 to change 94475 06/10/26, 21:53
-
Garvin Hicking commented and changed status
Under ReviewResolved done0 %100 % 06/10/26, 22:15Applied in changeset commit:643a4900bbe40f0894181136d91f9a3ef6dcbb5f.
-
Benni Mack changed status
ResolvedClosed 08/11/26, 08:50
Thanks for the report! Maybe you can try out the patch and see if this solves it for you?