shopping cart improvements, refactoring