mirror of
https://github.com/kevin-DL/LaravelShoppingcart.git
synced 2026-01-22 07:05:23 +00:00
Update Cart.php
This commit is contained in:
@@ -171,7 +171,7 @@ class Cart
|
||||
*/
|
||||
public function addCartItem(CartItem $item, bool $keepDiscount = false, bool $keepTax = false, bool $dispatchEvent = true): CartItem
|
||||
{
|
||||
$cartItem->setInstance($this->currentInstance());
|
||||
$item->setInstance($this->currentInstance());
|
||||
|
||||
if (!$keepDiscount) {
|
||||
$item->setDiscountRate($this->discount);
|
||||
|
||||
Reference in New Issue
Block a user