I'm facing this error when i try to login as customer, but when i go back or at Home i was logged in but every time i logout & login back, i face this error, also when i was logged in and go to My Account
i get this error, don't know why.
Fatal error: Uncaught Error: Call to a member function setUseContainer() on boolean in /var/www/html/vendor/magento/module-wishlist/Block/Customer/Wishlist.php:127 Stack trace: #0 /var/www/html/vendor/magento/framework/View/Element/AbstractBlock.php(283): Magento\Wishlist\Block\Customer\Wishlist->_prepareLayout() #1 /var/www/html/vendor/magento/framework/View/Layout/Generator/Block.php(149): Magento\Framework\View\Element\AbstractBlock->setLayout(Object(Magento\Framework\View\Layout\Interceptor)) #2 /var/www/html/vendor/magento/framework/View/Layout/GeneratorPool.php(81): Magento\Framework\View\Layout\Generator\Block->process(Object(Magento\Framework\View\Layout\Reader\Context), Object(Magento\Framework\View\Layout\Generator\Context)) #3 /var/www/html/vendor/magento/framework/View/Layout.php(343): Magento\Framework\View\Layout\GeneratorPool->process(Object(Magento\Framework\View\Layout\Reader\Context), Object(Magento\Framework\View\Layout\Generator\Context)) #4 /var/www/html/vendor/magento/framework/View/Layout/Builder.ph in /var/www/html/vendor/magento/module-wishlist/Block/Customer/Wishlist.php on line 127
Best Answer
I think i should add another answer and leave previous answer as it is for knowledge purpose. I realized that i'm missing something. a very simple way to resolve this issue.
i have two overridden files which are causing this error
customer_account_index.xml
&wishlist_index_index.xml
, i just addwishlist_item_pager
block to it's right place. Here it is:app/design/frontend/Magestore/theme/Magento_Customer/layout/customer_account_index.xml
app/design/frontend/Magestore/theme/Magento_Wishlist/layout/wishlist_index_index.xml