Editor’s note: The opinions in this article are the author’s, as published by our content partner, and do not necessarily represent the views of MSN or Microsoft.

The Post reports:

A federal appeals court panel has maintained the freeze on President Trump’s controversial immigration order, meaning previously barred refugees and citizens from seven Muslim-majority countries can continue entering the United States.

In a unanimous, 29-page opinion, three judges with the U.S. Court of Appeals for the 9th Circuit flatly rejected the government’s argument that the suspension of the order should be lifted immediately for national security reasons and forcefully asserted their ability to serve as a check on the president’s power.

The opinion tells us much about the hubris and sheer incompetence of the new administration as the court rebuked it at every turn, pointing to errors in law and lawyering.

The administration made the argument that the case was not even reviewable, despite ample precedent from the George W. Bush years. In its most memorable line of the opinion the judges held, “There is no precedent to support this claimed unreviewability, which runs contrary to the fundamental structure of our constitutional democracy.” The court pointed out that even in the immigration and national security realms the political branches are subject to judicial review. Given the president’s recent public hectoring and threats to hold the court responsible for any terror attacks if it upheld the lower court’s order, the court had every reason to eviscerate the claim of what amounts to executive supremacy. (One wonders if the president’s noxious attack on the judiciary also encouraged the three-judge panel to make the ruling unanimous.)

Karen Shore holds up a sign outside of the 9th U.S. Circuit Court of Appeals in San Francisco, Tuesday, Feb. 7, 2017. A panel of appeals court judges reviewing President Donald Trump’s travel ban hammered away Tuesday at the federal government’s arguments that the states cannot challenge the order.© AP Photo/Jeff Chiu Karen Shore holds up a sign outside of the 9th U.S. Circuit Court of Appeals in San Francisco, Tuesday, Feb. 7, 2017. A panel of appeals court judges reviewing President Donald Trump’s travel ban hammered away Tuesday at the… The most fatal flaw was the inclusion of green card holders, which the Department of Homeland Security apparently warned the White House not to include. This gave the court a significant group of people with due process rights who would be subject to presidential whim without any procedural recourse. Both green card holders here in the U.S. and those seeking to come back into the country were affected.

The White House realized after the executive order was issued that green card holders were a problem, but then made a stupid legal error. Rather than issue a new order the White House counsel issued “guidance” to say the order was not intended to affect green card holders. The court scoffed, “The Government has offered no authority establishing that the White House counsel is empowered to issue an amended order superseding the Executive Order signed by the President.” The government lawyers failed to show that the modification was even binding. Along with green card holders, the court found those with visas also are entitled to due process.

While the government chose not to rule directly on First Amendment grounds, it did dismiss the argument this was not a Muslim ban. The court found that “the States have offered evidence of numerous statements by the President about his intent to implement a ‘Muslim ban.’” On this, Trump dug his own legal grave.

In then weighing the “irreparable injury” that might be done by staying the ban, the court observed that the administration provided “no evidence that any alien from any of the countries named in the Order has perpetrated a terrorist attack in the United States.” In biting criticism the court found, “Rather than present evidence to explain the need for the Executive Order, the Government has taken the position that we must not review its decision at all.” This too was a complete failure of lawyering. Not a single affidavit or other showing attesting to the imminent harm to American national security was produced. In fairness to the executive branch’s lawyers though, maybe there simply is not any.

The White House seemed to believe that issuing an executive order was no different than putting out a campaign white paper. The court to its credited reminded the administration that presidents have ample, but not unlimited power. Constitutional restraints still apply to the president, even on national security.

A more rational president who actually believed national security was at risk would heed the court’s directions, issue a narrower ban that would pass muster and roll that out with proper coordination. But Trump must “win” and can never accept error — even if his aides deserve some of the blame. He’ll persist, he says, to the Supreme Court (or perhaps first to an en banc review). If he truly believes that we are in peril, it is he who is endangering the country by choosing to leave the country with no travel ban whatsoever. And of course, with regard to real risks — radicalized Americans, lone wolves, etc. — the president is doing nothing, thereby leaving the country no safer than it was under his predecessor.

This is a humiliating defeat for the White House, revealing just how amateurish the president and his advisers are. The frightful part is that if they cannot handle a simple executive order, what makes anyone think they can handle far more difficult challenges?