updating add to cart def