diff --git a/src/Cart.php b/src/Cart.php index 8d69209..08e7dde 100644 --- a/src/Cart.php +++ b/src/Cart.php @@ -751,7 +751,7 @@ class Cart * * @return \Gloudemans\Shoppingcart\CartItem */ - private function createCartItem($id, string $name, $qty, $price, $weight, array $options) : CartItem + private function createCartItem($id, ?string $name = null, $qty, $price, $weight, array $options) : CartItem { if ($id instanceof Buyable) { $cartItem = CartItem::fromBuyable($id, $qty ?: []);