Egyptian lawmakers worked feverishly to finish a draft of the new constitution on Thursday, rushing to beat a court ruling that could threaten its legitimacy.

Reuters reported that passage was expected Friday.

Egyptian state media are reporting on the assembly’s piecemeal progress as members vote on all 235 articles, one by one.

So far, the assembly has voted to limit presidents’ time in office to two terms of four years each. That measure will prohibit long tenures like the 30-year presidency of Hosni Mubarak, the dictator who was overthrown in last year’s Arab Spring revolution.

Opponents of Egyptian President Mohamed Morsi, a moderate Islamist who represents the Muslim Brotherhood, may rejoice at this news. They were incensed last week when the president issued a  decree that strengthened his own power at the expense of the judiciary system.

Morsi said Thursday night that his decree, which provoked protests and violence from Egyptians fearing a new dictator, was "for an exceptional stage."

"It will end as soon as the people vote on a constitution," he told state television. "There is no place for dictatorship."

The assembly was expected to finish approving the draft constitution on Friday, allowing a referendum to be held as soon as mid-December on a text the Islamists say reflects Egypt's new freedoms.

The decision to fast-track the constitution has two probable effects. It should hasten the end of Morsi’s power grab, which should please his critics. But it will also enable Islamists, who make up most of the assembly, to finalize the draft without much interference from secularists and Christians.

The mad rush began in response to a threat from the courts. Judges vowed this week to rule on the legitimacy of the constitutional assembly on Sunday, even though such a move would be prohibited under Morsi’s decree. Lawmakers decided to work toward a quick draft approval on Thursday in order to beat the judiciary to the punch.

The presidential term limit is only one of the articles that have been approved so far. The assembly has also agreed on a clause that guarantees freedom of the press, subject to the judgment of the court, according to the BBC.

Other clauses may be worrisome to Egypt’s non-Muslim citizens.

One provision states that the “principles” of Shariah would be a “main source of legislation.” Another says the state would protect “the true nature of the Egyptian family ... and promote its morals and values.” Women's rights groups are already up in arms over this news.

Assembly leader Hossam al-Ghiryani expressed pride in the document, according to CBS.

"The Egyptian people are with us, listening to us," he said. "They must understand their constitution which they will vote on shortly and with which life will stabilize in Egypt, God willing."

But other leaders are less than pleased, including reformist and Nobel Peace Prize recipient Mohammed ElBaradei.

"I am saddened to see this come out while Egypt is so divided," he said, according to the Associated Press.  "It will be part of political folklore and will go to the garbage bin of history."

The constitutional draft will have to survive a public referendum before taking effect.