Whenever there shall occur in any county office in this State a loss of public funds arising through defalcation, bank deposits, theft or otherwise, the county treasurer or other officer having custody of the records in which such loss appears may charge off such loss with the approval of the county council, but, in the case of bank losses, only if the bank shall have been liquidated and the receiver or other agent discharged and, in the case of any other loss, only if the sums recoverable by bond or otherwise shall have been applied against the loss and the remaining sum definitely ascertained to be irrecoverable.