Topmenu template is not loaded from the original module #4564
Labels
Area: Frontend
bug report
Issue: Format is not valid
Gate 1 Failed. Automatic verification of issue format is failed
Steps to reproduce
2.0
branch.Magento\Theme\Block\Html\Topmenu
<preference for="Magento\Theme\Block\Html\Topmenu" type="MyCompany\Theme\Block\Html\Topmenu" />
Expected result
Actual result
Cause
The template of this block is not prefixed with the module name: https://github.com/magento/magento2/blob/develop/app/code/Magento/Theme/view/frontend/layout/default.xml#L69
Instead of :
<block class="Magento\Theme\Block\Html\Topmenu" name="catalog.topnav" template="html/topmenu.phtml" ttl="3600" before="-"/>
It should be:
<block class="Magento\Theme\Block\Html\Topmenu" name="catalog.topnav" template="Magento_Theme::html/topmenu.phtml" ttl="3600" before="-"/>
Could you please confirm that is a bug so I can make a PR to fix that.
The bug was discovered in this Magento SE post: http://magento.stackexchange.com/questions/115988/are-we-forced-to-rewrite-a-template-in-magento2-when-rewritting-a-block
The text was updated successfully, but these errors were encountered: