Guest cart session is not getting removed after last item deletion
This commit is contained in:
parent
db5916f7dd
commit
0f23443a17
|
|
@ -274,7 +274,7 @@ class Cart
|
|||
if ($cartItem = $cart->items()->find($itemId)) {
|
||||
$cartItem->delete();
|
||||
|
||||
if ($cart->items->count() == 0) {
|
||||
if ($cart->items()->get()->count() == 0) {
|
||||
$this->cartRepository->delete($cart->id);
|
||||
|
||||
if (session()->has('cart')) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue