Updated

Libya's top court on Monday rejected the Islamist-led parliament's appointment of a new prime minister, a ruling likely to deepen the country's crisis amid a power struggle between the assembly and a rival government.

The Supreme Constitutional Court said Prime Minister Ahmed Maiteg's appointment was unconstitutional, but gave no further details or instructions.

Maiteg was elected last month by the Islamist-led parliament in a contested vote, which prompted incumbent Prime Minister Abdullah al-Thinni to refuse to hand over the post until the judiciary decides on the matter.

The ruling comes as Libya's renegade Gen. Khalifa Hifter is waging an offensive against Islamist militias.

Over the past weeks, forces allying with Hifter have bombed camps of Islamist militias, which responded by waging attacks on his forces, including an assassination attempt on Hifter himself. Hifter survived the suicide attack on his residence in the eastern city of Benghazi that killed four people earlier this month.

The general has also warned he will detain Islamist lawmakers, accusing them of financing militias which he blames for much of Libya's chaos.

Libya has sunk into chaos in recent past years following the downfall and the killing of longtime dictator Moammar Gadhafi in the country's 2011 civil war.

The case against Maiteg's appointment was taken to the Supreme Constitutional Court by 12 lawmakers.

Last week, Maiteg, a businessman who owns a five-star hotel in Tripoli was escorted by militiamen from the Libya Central Shield — one of several militias on the government's payroll — into the government headquarters in the Libyan capital, where he held his first Cabinet meeting behind closed doors.