Bug #86719
closedAdminpanel SubModuleRenderViewHelper throws exception while not implementing ContentProviderInterface
0%
Description
Currently while not implementing a ContentProviderInterface and therfore not implementing method `getContent()` throws an InvalidArgumentException: `The argument "module" was registered with type "TYPO3\CMS\Adminpanel\ModuleApi\ContentProviderInterface", but is of type "Psychomieze\AdminpanelExtended\Modules\Info\InternalContentObjects" in view helper "TYPO3\CMS\Adminpanel\ViewHelpers\SubModuleRenderViewHelper".`.
This happens only right after all caches have been cleared.
Using "warmed up" caches will throw `Call to undefined method Psychomieze\AdminpanelExtended\Modules\Info\InternalContentObjects::getContent()`
Files
Updated by Susanne Moog about 6 years ago
- Status changed from New to Resolved
The submodule render viewhelper should render modules - it can only render modules that provide something to render... This is by design, the argument is therefor registered with the appropriate interface.
Updated by Jan Stockfisch about 6 years ago
That may all be correct and especially if this is by design then AbstractSubModule should implement ContentProviderInterface by default, shouldn't it?