2

Has anyone noticed this in Query.php?

Found in app/code/core/Mage/CatalogSearch/Model

There are a few references to 'MinQueryLenght' instead of 'MinQueryLength'. I'm assuming it's a typo so have changed it but surely this could have quite severe effects on the search functionality?

1 Answer 1

1

Just had a look at the file in question you are indeed correct about it being a typo. I would not recommend you alter the file to fix this, as this would break with future upgrade path and also it looks as if they are looking to fix this functionality in the process.

/**
 * Retrieve minimum query length
 *
 * @deprecated after 1.3.2.3 use getMinQueryLength() instead
 * @return int
 */
public function getMinQueryLenght()
{
    return Mage::getStoreConfig(self::XML_PATH_MIN_QUERY_LENGTH, $this->getStoreId());
}

/**
 * Retrieve minimum query length
 *
 * @return int
 */
public function getMinQueryLength(){
    return $this->getMinQueryLenght();
}
1
  • 1
    Oh I completely agree, I'd never edit a core file, simply copied it to the 'local' folder
    – James Lane
    Commented May 18, 2015 at 12:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.