Skip to content

Commit deced22

Browse files
authored
Fixed null parameter warning in Mage_Catalog_Model_Layer_Filter_Attribute (#3926)
1 parent 095ed12 commit deced22

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

app/code/core/Mage/Catalog/Model/Layer/Filter/Attribute.php

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,10 @@ public function apply(Zend_Controller_Request_Abstract $request, $filterBlock)
7878
return $this;
7979
}
8080
$text = $this->_getOptionText($filter);
81+
if (!is_string($text)) {
82+
return $this;
83+
}
84+
8185
if ($filter && strlen($text)) {
8286
$this->_getResource()->applyFilterToCollection($this, $filter);
8387
$this->getLayer()->getState()->addFilter($this->_createItem($text, $filter));

0 commit comments

Comments
 (0)