Fixed error in "debit" function