Updating products in cart and calculating discounts