fix some errors in checkout