adds logic for checkout button