and store the refund correctly