2

I have a code:

$productCollectionClone = $productCollection->getCollectionClone();
$collection = $productCollectionClone->removeAttributeSearch($attribute->getAttributeCode());

Anyone can help me explain how the function removeAttributeSearch work?

6
  • 1
    This is not a default Magento function. It seems you are using mageplaza layered navigation extension. Can you please confirm ? Aug 6 '19 at 10:06
  • Yes, You're right. Thank you. I have a bug with Magento 2.3.2. Call to undefined method Magento\CatalogSearch\Model\ResourceModel\Fulltext\Collection\Interceptor::getCollectionClone(). Do you know how to fix it? Aug 6 '19 at 10:11
  • 1
    It seems the Fulltext Search Model is not properly overriden, because its trying to call getCollectionClone() on core module and its not part of core functionality. Have you added this module recently ? Aug 6 '19 at 10:29
  • Yes, I have installed this module. When I try to filter, I get this issue. Aug 6 '19 at 10:34
  • Hello, @AbdulPathan did you found solution? Jan 20 '20 at 10:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.