edited code to fix another compare cart bug