Fix minor bugs in repayment window