Closed murwiz closed 9 years ago
Note: ... shop_cart()->apply_cost( name => 'shipping', amount => 1.23 ); debug(shop_cart()->cost('shipping')); ... Bad argument to cost: shipping
If you dump out shop_cart()->costs, you see an empty array.
However, this works:
my $cart = shop_cart(); $cart->apply_cost( ... );
This is a general problem, we don't cache the cart object anymore like we did in Dancer::Plugin::Nitesi.
Closed by commit 16afd053
Note: ... shop_cart()->apply_cost( name => 'shipping', amount => 1.23 ); debug(shop_cart()->cost('shipping')); ... Bad argument to cost: shipping
If you dump out shop_cart()->costs, you see an empty array.
However, this works:
my $cart = shop_cart(); $cart->apply_cost( ... );