CAIRO: Egypt’s top court on Thursday ordered a retrial of Muslim Brotherhood leader Mohamed Badie, overturning a death sentence for protest violence, a judicial official and a lawyer said.

Thirty-six codefendants who were condemned to death or life in prison by a lower court will be retried along with Badie, who has also been sentenced to death in a different case.

They had been found guilty of plotting unrest from an “operations room” in a Cairo protest camp in the months after the army ousted President Muhammad Mursi in 2013.

The convictions were appealed before the Court of Cassation, which on Thursday overturned them and ordered a retrial.

“The ruling concerns all 37 defendants who are behind bars. Twelve of them including Badie had been sentenced to death” by the lower court, defense lawyer Abdel Moneim Abdel Maqsud told AFP.

Badie’s codefendants include US-Egyptian citizen Mohamed Soltan, who had been sentenced to life in prison.

Soltan was deported in May under a presidential decree stipulating that foreigners convicted in Egypt can be sent back to their home countries.