Gernott / mask

TYPO3 Extension Mask
https://www.facebook.com/typo3mask
GNU General Public License v2.0
130 stars 86 forks source link

Breaking Change (Mask 7.2.1 requires TYPO3 v11) in Inlinehelper / Relations Error #490

Closed woodyc79 closed 2 years ago

woodyc79 commented 2 years ago

Hello!

On TYPO3 10.4.28 and with Mask 7.2.1 i get the following error: Argument 2 passed to TYPO3\CMS\Core\Domain\Repository\PageRepository::getLanguageOverlay() must be of the type array, null given, called in /var/www/html/web/typo3conf/ext/mask/Classes/Helper/InlineHelper.php on line 214

I have a selectbox where i let the user select a tt_content element based on tt_content.ctype="mask_anotherelement"

On line 214 of InlineHelper.php i have this code $translatedRecord = $pageRepository->getLanguageOverlay($tableName, $relation['record']);

If I debug RelationHandler->getResolvedItemArray, I cannot see any line that would fill the array with ['record'], I think this is ONLY for TYPO3 v11 (master branch): https://api.typo3.org/master/_relation_handler_8php_source.html#l01248 vs. TYPO3 v10.x: https://api.typo3.org/10.4/_relation_handler_8php_source.html#l01252

There should be a change in the composer.json as it requires TYPO3 v 11, or maybe you could make it backwards compatible to T3v10.x?

Kind regards, Christian

nhovratov commented 2 years ago

Hi Christian, thanks for reporting the error! I will release a new version now.