If the county legislative authority has required the petitioners to make a cash deposit or furnish a bond, upon completion of the hearing, it shall certify all costs and expenses incurred in the proceedings to the county treasurer and, regardless of its final decision, the county legislative authority shall recover all such costs and expenses from the bond or cash deposit and release any balance to the petitioners.