The Supreme Court just dealt a staggering blow to the L.G.B.T. rights movement. And no, it had nothing to do with wedding cake. While the eyes of most L.G.B.T. advocates this term were concentrated on Masterpiece Cakeshop v. Colorado Civil Rights Commission, the legal ruling was decidedly narrow. The court’s 5-4 decision today in Janus v. American Federation of State, County, and Municipal Employees, however, will have immediate and lasting implications for the livelihoods of queer people.

In Janus, the court ruled, on First Amendment grounds, that public-sector employees who do not join their workplace’s labor union cannot be required to pay “fair share fees” to cover the costs of collective bargaining, even though all unions have an obligation to represent paying members and nonmembers alike. Because union membership today is five times higher in the public sector than in the private sector, the ruling is expected to drain organized labor’s already diminished coffers.

Today’s decision will weaken the power of more than five million public workers in the remaining 22 states that allow unions to collect fees. And since public- and private-sector employees often share the same parent union (such as the A.F.T., the S.E.I.U. and the U.A.W.), the Janus decision is likely to deplete resources for worker organizing in private industries, too.

What does any of this have to do with L.G.B.T. rights? State and local governments employ an estimated one million people who identify as L.G.B.T. Without funds for unions to sustain services and organizing, L.G.B.T. employees are at risk: In the 29 states lacking full protections against employment discrimination for sexual orientation and gender identity, a collective bargaining agreement with a nondiscrimination provision is often a worker’s only refuge.