Completing the cart functionality