The Department of Justice is weighing whether or not to appeal a decision issued by the Ninth Circuit Court of Appeals to deny reinstating President Donald Trump's immigration order while its legality is established, according to multiple reports Friday.

That's because the White House is apparently rewriting the controversial executive order which temporarily bans immigration from six predominantly Muslim countries and permanently from Syria so that it has a better chance of withstanding legal challenges.

Trump tweeted on Thursday night that he intends to appeal the Ninth Circuit's decision: "SEE YOU IN COURT," he wrote shortly after the judges issued their 29-page opinion. But he wavered on that pronouncement Friday, saying he "very well could" issue a "brand new order" next week.

Legal experts say rewriting the order is likely a much better option for the Trump administration than sticking with the "extreme vetting" order in its current form, which would likely result in more litigation.Legal experts say rewriting the order is likely a much better option for the Trump administration than sticking with the "extreme vetting" order in its current form, which would likely result in more litigation.

"There are a variety of things the government could do to help their case. It's just a matter of how much they're willing to change the executive order," said Stephen Yale-Loehr, a professor of immigration law at Cornell University.

Yale-Loehr said that the order's most controversial sections 3(c) and the near entirety of section 5, which were the subject of a lawsuit brought by Washington and Minnesota against the government that ultimately resulted in the temporary restraining order (TRO) placed on the ban would either have to be changed significantly or removed entirely if the administration wanted to shield itself from further litigation.

Section 3(c) of the immigration order stipulates that "immigrant and nonimmigrant entry into the United States of aliens from" Iraq, Syria, Sudan, Iran, Somalia, Libya and Yemen "would be detrimental to the interests of the United States," and that Trump would "hereby suspend entry into the United States, as immigrants and nonimmigrants, of such persons for 90 days from the date of this order." The original order did not list the countries specifically but referred to those targeted in an Obama-era visa-waiver policy, the Department of Homeland Security later clarified.

The nationwide enforcement of Section 3(c) was restrained "in its entirety" last week by US District Judge James Robart, who sided with the states' argument that the order caused "significant and ongoing harm" to "substantial numbers of people, to the detriment of the States."

When Robart asked the government lawyer, Michelle Bennett, if there had been any terrorist attacks by people from the seven counties listed in Trump's order since 9/11, Bennett said she didn't know.

"The answer is none," Robart said, according to Reuters. "You're here arguing we have to protect from these individuals from these countries, and there's no support for that." Even after appealing the restraining order to the Ninth Circuit, the government still had difficulty proving that citizens from the seven countries posed an elevated terror risk above others.

"The proceedings have been moving very fast," the Department of Justice lawyer, August Flentje, told Ninth Circuit Judge Michelle Friedland when she asked whether the government had any evidence connecting the seven nations targeted by the order to terrorism.