fixed bug: 'nil cart'