Closed kristindiannefoss closed 8 years ago
refactor: @cart.contents[params["item_id"]] = params["session"]["quantity"].to_i
@cart.remove_items
in cart.rb: instead of total price just do items.reduce(0) { | sum, item | sum + item.subtotal}
can get rid of sub total inside of cart
refactor: @cart.contents[params["item_id"]] = params["session"]["quantity"].to_i
@cart.remove_items
in cart.rb: instead of total price just do items.reduce(0) { | sum, item | sum + item.subtotal}
can get rid of sub total inside of cart