While details of implementation at the local level remain to be determined, the U.S. Supreme Court on Thursday ruled that the federal moratorium against evictions during the COVID-19 pandemic is illegal.

However, the six-justice majority reached that conclusion in a most troubling manner: It undermined an act of Congress without ruling that the law in question in any way violates the U.S. Constitution.

The moratorium had explicit Congressional authorization from March 2020 through January 2021, and has continued because the Biden administration invoked a 1944 law that gives the executive branch the authority to combat communicable diseases. All along, the moratorium’s backers have had a couple motives for supporting it.

One is disease control: A wave of homelessness and migration could help spread the coronavirus. The other is economic: With work hard to come by as the pandemic set in last year, many renters found themselves falling behind on their financial obligations through no fault of their own.

The opposition, from landlords and their representatives, has a singular motive: Without rent coming in, they’re having trouble meeting their own financial obligations. At some point, everyone agrees, business practices have to return to normal.

The 1944 law — the Public Health Service Act — gives the U.S. surgeon general the authority to “make and enforce such regulations as in his judgment are necessary” to prevent the spread of communicable diseases from state to state.

And after next providing some examples — “inspection, fumigation, disinfection, sanitation, pest extermination, [or] destruction of animals or articles” that have been contaminated — the law reiterates that the surgeon general is free to pursue “other measures, as in his judgment may be necessary.”

But the justices in the majority deemed the examples Congress provided in 1944 as signaling that legislators intended to give the surgeon general only limited authority.

Holding that Congress should “speak clearly when authorizing an agency to exercise powers of vast economic and political significance,” they said there can be no federal eviction moratorium without new legislation.

But Congress did speak clearly in 1944.

The justices waved off the law’s repetition of the word “necessary,” and its use of the phrase “other measures” to give the surgeon general room to deal with contingencies legislators might not have anticipated.

When interpreting statutes, judges are supposed to give weight to every word of their text. The Supreme Court failed to do that here.

And it ignores history to argue that Congress in 1944 was blind to the reality it was potentially authorizing things of “vast economic and political significance.” By that point, it and President Franklin Roosevelt had already reordered the entire U.S. economy to fight and win World War II. The Public Health Service Act was consistent with that mentality.

Nor does it help to argue, as the justices did in their unsigned opinion, that the moratorium is unprecedented in size or scope and thus incomparable to any disease-control measure since the law went into effect in the summer of 1944. In that timeframe, so is the COVID-19 pandemic.

The Constitution gives Congress the power to regulate interstate commerce, and the only nod the justices made to that was to acknowledge that resuming evictions could prompt “some subset of tenants” to move from state to state, and that “some subset of that group might” have COVID.

But their references to the Constitution ended with that, leaving us with another example of the court on its own hook whittling down laws that presumptively pass Constitutional muster. We’ve seen that a number of times in the civil-rights arena. We’ve even seen the court negate actual Constitutional provisions: In resolving North Carolina’s redistricting quarrel in 2019, justices said the Constitution’s guarantee of a state-level “republican form of government” — i.e. a representative one, as opposed to a monarchy or dictatorship — is unenforceable by federal judges.

For renters in North Carolina, the good news is that this state is among the relative few that have worked hard to get federal relief aid to them that’s meant to help cover their rent and utilities. The aid is not moving as fast as it should, but North Carolina distributed $32.3 million between Jan. 1 and May 31, the U.S. Treasury Department says. That’s a whole lot better than neighboring Tennessee ($4.1 million) or South Carolina ($0).

Virginia, however, distributed $155.5 million in that time. That suggests there’s a lot of work left to do here.