Added autofinalize/refund feature