Skip to content

Commit

Permalink
Merge pull request #108 from magento-engcom/fix-calls-count
Browse files Browse the repository at this point in the history
MAGETWO-89384 Fix Calls to count() - CE
  • Loading branch information
Joan He authored Mar 31, 2018
2 parents 83c2aff + cd01eba commit 7d5bae7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion app/code/Magento/Wishlist/Observer/AddToCart.php
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public function execute(Observer $observer)
$wishlistIds = [$singleWishlistId];
}

if (count($wishlistIds) && $request->getParam('wishlist_next')) {
if (is_array($wishlistIds) && count($wishlistIds) && $request->getParam('wishlist_next')) {
$wishlistId = array_shift($wishlistIds);

if ($this->customerSession->isLoggedIn()) {
Expand Down

0 comments on commit 7d5bae7

Please sign in to comment.