President Trump may have lost the early legal skirmishes over his executive order on immigration, but in the end he will likely win.

The overwhelming weight of history and the law is on his side. The president does have the authority to ban the entry of foreigners, as long as he has what is called a “rational basis” to believe they pose a threat to the nation’s security. He does, and his order is designed to accomplish precisely that.

The seven nations targeted by Trump in his immigration ban were originally identified in an anti-terrorism law signed by President Obama. Unlike other Muslim-majority nations that have a history of terrorism, these seven countries do not assist the U.S. in providing background checks and other vetting of immigrant applicants. Thus, it is not only “rational” to deny entry, it is imperative for the safety of Americans. The U.S. does not have the resources to properly vet all these individuals on its own.

Shortly after the executive order was put in place, several federal court judges issued temporary restraining orders. Most of those TROs halted the detention and deportation of foreigners who had already been issued legal immigration visas. Many had already arrived in the U.S.

But that is a very small part of the president’s order. The merits of those TROs, not to mention the president’s order itself, have yet to be fully litigated. The judicial rulings were issued “ex parte”. That is, only one side was represented in court. The Trump administration lawyers haven’t even been given a chance to appear in court to say, “good morning, your honor.” All of that may change once both sides are represented in court.

The Washington State Case

The ruling in Seattle by U.S. District Court Judge James Robart was different and far more expansive. He issued a temporary hold on the immigration ban nationwide. Lawyers at the Department of Justice appealed to the 9th Circuit which refused to overturn Judge Robart’s ruling, although further briefs have been filed. Thereafter, the 9th Circuit could revisit its decision.

It is no surprise that the 9th Circuit got it wrong. It is the most overturned appellate court in the nation. There’s a joke among California lawyers: if you lose your case in the 9th Circuit, you’re assured of winning it before the Supreme Court. Get the picture?

Nevertheless, the Seattle ruling is the case to watch, in part because Washington became the first state to sue. Take a look at judge Robart’s decision. It is largely devoid of any legal reasoning or sound analysis. Its brevity is exceeded only by its lack of logic as applied to the law.

Absence of Standing to Sue

Washington State does not have “standing” to sue on behalf of its residents because they have suffered no "actual harm" from Trump's order.

In order to sustain a lawsuit, the plaintiffs must demonstrate their alleged injury is direct and real, not merely hypothetical. The harm must be imminent and irreparable, not speculative.

So how have Washington residents been harmed? Lawyers for the state suggest their economy will be adversely impacted because the ban may prevent immigrants from working for Washington-based companies. Taxes might be reduced and its education system could be affected.

However, all of that is pure conjecture. It might happen, but it might not. Hence, it does not constitute immediate “actual harm.” On that basis alone, the lawsuit should be dismissed.

Foreigners Do Not Enjoy Constitutional Rights

The vast majority of people affected by President Trump’s executive order are people who do not have legally valid immigration visas but are seeking entry to the United States by undertaking the lengthy application process. We are talking about hundreds of thousands of people.

The claim by Washington State that the immigration ban violates the First Amendment (freedom of religion) or the Fifth and Fourteenth Amendments (equal protection clause) may seem, at first blush, like a reasonable argument. Until you consider that our Constitution applies only to citizens and those on American soil.

A man in Somalia may wish to invoke our Constitution to claim his freedom of religion is being infringed, but until he arrives here he enjoys none of its privileges and protections. He has no right to assert discrimination, religious or otherwise. And the state of Washington has no legal right to represent him in court. It can only represent its own residents.

The President Has Authority to Dictate Immigration

Article 1, Section 8 of the Constitution gives Congress the power to regulate immigration. In 1952, Congress passed a law empowering the president to deny entry into the U.S. to “any class of aliens” considered to be “detrimental to the interests of the United States.” In other words, a threat to America and in the interests of national security.

As I pointed out in a recent column, the Supreme Court has repeatedly ruled that Congress and the president have “plenary power” to regulate immigration. For more than a century, the high court has consistently upheld such authority and rejected constitutional challenges to presidential action banning entire groups of foreigners. Even the 9th Circuit has endorsed this legal principle. Past presidents, including Carter and Obama, have issued orders similar to Trump’s.

It is true that a subsequent 1965 immigration law prohibits discrimination based on race, sex, nationality, place of birth or place of residence. But that law says nothing about religion. And, more importantly, it applies only to the issuance of visas. The president’s authority to deny entry to a large class of aliens is a broader power which supersedes individual visa considerations.

Trump’s Executive Order Is Temporary

Lost in all the legal tumult is the fact that President Trump’s executive order is only temporary: It applies for just 90 days for people in the seven designated countries that are sources of terrorism and 120 days for “refugees.” (The Syrian ban is “indefinite,” but that could change, too.)

By the time each side has had the opportunity to fully litigate the merits of the various cases and undertaken the usual course of appeals, the executive order will likely have expired. That may render most of the cases moot. Absent a legal controversy, there would be nothing for judges to resolve. The petitions and lawsuits would probably be dismissed.

For now, however, the Seattle case may head to a hearing before the full complement of judges on the 9th Circuit Court, known as an “en banc” session. Or, the Department of Justice may seek an emergency application to the U.S. Supreme Court.

The latter action might be imprudent, since the current court has only eight sitting justices. A 4-4 tie would allow the 9th Circuit’s decision to stand. It would make more sense to wait for the confirmation of Neil Gorsuch to cast the ninth, and perhaps deciding, vote. Given the great weight of the law in favor of the president, the decision should be unanimous. But why take the chance?

Unwise To Attack a Federal Judge

True to form, President Trump launched a Twitter attack on Judge Robart’s decision, calling him a “so-called judge” who issued a “ridiculous” decision. I agree, the decision is ridiculous to the extent it is based on scant legal analysis and completely contravenes long established law.

Nevertheless, it is unwise and counterproductive to personally insult or demean a judge by questioning his legitimacy. Judges tend to be a collegial group. An attack on one may be viewed as an attack on all. Why create an underlying reason in the minds of appellate judges to find a way to support one of their brethren?

A better strategy would be to compliment the Boston judge who affirmed Mr. Trump’s executive order. In a 21 page decision issued on February 3, Judge Nathaniel M. Gorton eloquently explains the power of the president embedded in sturdy constitutional principles. It is a thoughtful and comprehensive treatise on how our laws and the courts have spoken in unison on immigration authority.

If any of these immigration cases ever reach the Supreme Court, Judge Gorton’s opinion may be the foundation for their decision.