Rob Ford has won his court battle to keep his job as mayor of Toronto.

A Divisional Court panel today struck down a previous ruling that Ford should be dismissed from office for violating conflict of interest rules.

The three-judge panel agreed with Ford’s lawyers, who had argued the previous ruling was legally flawed.

In November, an Ontario Superior justice ordered Ford removed as mayor for taking part in a council vote that he repay $3,150 raised for his private football foundation.

The ruling was put on hold pending today’s decision.

Despite the legal win, Ford’s woes are not done. An audit of his campaign expenses is pending.