Bug #99637
closedstr_starts_with(): Argument #1 ($haystack) must be of type string, int given
100%
Description
Currently the Frontend crashes, when you have the AdminPanel enabled and try to insert an _INT Content-Object.
Steps to reproduce:
- enable admin panel
- print out current date uncached (*1)
- reload frontend
*1
TypoScript: lib.currentDate = COA_INT lib.currentDate { 10 = TEXT 10.stdWrap.data = date:U 10.stdWrap.strftime = %H:%M:%S } Fluid: <f:cObject typoscriptObjectPath="lib.currentDate" />
Attached a Screenshot from where the exception comes.
"10" as key is not a valid yes in XLIFF-File und does not need to get translated at this point.
Solution:
Cast the assigned id (in this case an integer) to a string in `TranslateViewHelper` before line 147: `$id = (string)$id;`
Files
Updated by Henrik Ziegenhain almost 2 years ago
- File adminpanel-type-bug.png adminpanel-type-bug.png added
Updated by Gerrit Code Review almost 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/+/77495
Updated by Gerrit Code Review almost 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/+/77495
Updated by Henrik Ziegenhain almost 2 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset faed1d021bd1759e8b3a011f5c894ea3b7a17d66.