Skip to content

Commit c527499

Browse files
authored
warning - fix undefined array key labels (#4777)
1 parent 8c9d8ee commit c527499

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/code/core/Mage/ConfigurableSwatches/Helper/Productimg.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ public function filterImageInGallery($product, $image)
376376

377377
if (!isset($this->_productImageFilters[$product->getId()])) {
378378
$mapping = call_user_func_array('array_merge_recursive', array_values($product->getChildAttributeLabelMapping()));
379-
$filters = array_unique($mapping['labels']);
379+
$filters = isset($mapping['labels']) ? array_unique($mapping['labels']) : [];
380380
$filters = array_merge($filters, array_map(function ($label) {
381381
return $label . Mage_ConfigurableSwatches_Helper_Productimg::SWATCH_LABEL_SUFFIX;
382382
}, $filters));

0 commit comments

Comments
 (0)