File tree 1 file changed +3
-3
lines changed
app/code/Magento/ConfigurableProduct/Model/Product/Type 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -443,15 +443,15 @@ public function getConfigurableAttributes($product)
443
443
*/
444
444
protected function hasCacheData ($ configurableAttributes )
445
445
{
446
- $ configurableAttributes = $ configurableAttributes ?: unserialize ($ configurableAttributes );
447
- if (is_array ($ configurableAttributes ) && count ($ configurableAttributes )) {
446
+ $ configurableAttributes = $ configurableAttributes ? unserialize ($ configurableAttributes ) : $ configurableAttributes ;
447
+ if (( is_array ($ configurableAttributes) || $ configurableAttributes instanceof \Traversable ) && count ($ configurableAttributes )) {
448
448
foreach ($ configurableAttributes as $ attribute ) {
449
449
/** @var \Magento\ConfigurableProduct\Model\Product\Type\Configurable\Attribute $attribute */
450
450
if ($ attribute ->getData ('options ' )) {
451
451
return $ configurableAttributes ;
452
452
}
453
453
}
454
- }
454
+ }
455
455
return false ;
456
456
}
457
457
You can’t perform that action at this time.
0 commit comments