I tried find a solution to this magento 2 theme problem. How should be edit the theme file?
PHP Fatal error: Uncaught Error: Call to undefined method MagentoCatalogSearchModelResourceModelFulltextCollectionInterceptor::getCollectionClone() in app/code/custom_theme/LayeredAjax/view/frontend/templates/layer/filter.phtml:15
Stack trace:
#0 vendor/magento/framework/View/TemplateEngine/Php.php(59): include()
#1 vendor/magento/framework/View/Element/Template.php(271): MagentoFrameworkViewTemplateEnginePhp->render(Object(MagentoLayeredNavigationBlockNavigationFilterRendererInterceptor), '/home/npartsco/...', Array)
#2 vendor/magento/framework/View/Element/Template.php(301): MagentoFrameworkViewElementTemplate->fetchView('/home/npartsco/...')
#3 vendor/magento/module-layered-navigation/Block/Navigation/FilterRenderer.php(29): MagentoFrameworkViewElementTemplate->_toHtml()
#4 vendor/magento/framework/Interception/Interceptor.php(58): Mage in app/code/custom_theme/LayeredAjax/view/frontend/templates/layer/filter.phtml on line 15
line 12-23
< ?php
$productCollection = $filter->getLayer()->getProductCollection();
$productCollectionClone = $productCollection->getCollectionClone();
$collection = $productCollectionClone
->removeAttributeSearch(['price.from', 'price.to']);
$min = $collection->getMinPrice();
$max = $collection->getMaxPrice();
list($from, $to) = $requestValue ? explode('-', $requestValue) : [$min, $max];
?>