When money has been deposited, if it remains on deposit at the time of a judgment for the payment of a fine, the clerk of the court receiving the deposit must, under the direction of the court, apply the money in satisfaction thereof and, after satisfying the fine and costs, must refund the surplus, if any, to the defendant.
Ala. Code § 15-13-42 (1975)