MOUNT VERNON, N.Y. (CBSNewYork) – A state Supreme Court judge has ruled that Andre Wallace will serve as mayor of Mount Vernon until the end of the year.

There’s been a battle to run the city since then-Mayor Richard Thomas was convicted of corruption charges in July.

Thomas refused to leave office.

Wallace was initially appointed acting mayor, but he was then ousted by the City Council.

The fight over city control lasted five weeks.

“It was very difficult because it put our police and everybody else in a very precarious situation because they didn’t know who to answer to. My concerns were always that, thank god we didn’t have any serious, serious emergencies or no disasters,” Wallace said.

In November, Mount Vernon voters will elect a new mayor who will take office in January.