I am using Magento 2 and porto theme. My issue is with layered navigation.
When I search anything in my store results shows along with custom attribute filters, created through Store > Attribute > Product.
When results shows and I click on attribute to filter further ajax loads and nothing happens. These are the errors I can see in console.
Fatal error: Uncaught Error: Call to a member function toHtml() on boolean in /app/code/Mageplaza/LayeredNavigation/Controller/Search/Result/Index.php:132
Stack trace:
#0 /public_html/generated/code/Mageplaza/LayeredNavigation/Controller/Search/Result/Index/Interceptor.php(24): Mageplaza\LayeredNavigation\Controller\Search\Result\Index->execute()
#1 /public_html/vendor/magento/framework/App/Action/Action.php(107): Mageplaza\LayeredNavigation\Controller\Search\Result\Index\Interceptor->execute()
#2 /public_html/vendor/magento/framework/Interception/Interceptor.php(58): Magento\Framework\App\Action\Action->dispatch(Object(Magento\Framework\App\Request\Http))
#3 /public_html/vendor/magento/framework/Interception/Interceptor.php(138): Mageplaza\LayeredNavigation\Controller\Search\Result\Index\Interceptor->___callParent('dispatch', Array)
#4 /public_html/vendor/magento/framework/Interception/Interceptor.php(153): Mageplaza\LayeredNa in /public_html/app/code/Mageplaza/LayeredNavigation/Controller/Search/Result/Index.php on line 132
Please help. Thank you in advance.