Skip to content

Commit eea585a

Browse files
authored
Update Configurable.php
1 parent c7f0b4b commit eea585a

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

app/code/Magento/ConfigurableProduct/Block/Cart/Item/Renderer/Configurable.php

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ class Configurable extends Renderer implements IdentityInterface
2424
/**
2525
* Get item configurable child product
2626
*
27-
* @return \Magento\Catalog\Model\Product
27+
* @return \Magento\Catalog\Model\Product|null
2828
*/
2929
public function getChildProduct()
3030
{
@@ -66,7 +66,8 @@ public function getProductForThumbnail()
6666
if ($this->_scopeConfig->getValue(
6767
self::CONFIG_THUMBNAIL_SOURCE,
6868
\Magento\Store\Model\ScopeInterface::SCOPE_STORE
69-
) == ThumbnailSource::OPTION_USE_PARENT_IMAGE || !($this->getChildProduct()
69+
) == ThumbnailSource::OPTION_USE_PARENT_IMAGE
70+
|| !($this->getChildProduct()
7071
&& $this->getChildProduct()->getThumbnail() && $this->getChildProduct()->getThumbnail() != 'no_selection')
7172
) {
7273
$product = $this->getProduct();

0 commit comments

Comments
 (0)