Porting more functionalities of the cart