Any salary paid pursuant to an ordinance shall be in lieu of all costs and fees allowed a mayor of the town, whether acting as mayor of the town or magisterial district judge, and in such case, the costs and fees shall be taxed and collected by the mayor of the town and turned into the town treasury.
53 P.S. § 53158