An 18-year-old gunman stormed a Texas elementary school on Tuesday and killed 19 children and two teachers, reigniting a debate in the United States over gun control and the potential legal liability for manufacturers of firearms.

Below is a look at attempts to use the courts to hold manufacturers liable for mass shootings.

U.S. Gun Companies Are Generally Protected From Lawsuits

Since 2005, the Protection of Lawful Commerce in Arms Act (PLCAA) has provided near blanket immunity for gun makers and dealers from liability for crimes committed with their products. The law was passed after lawsuits by several cities tried to hold companies liable for gun violence. (Related article: Risk Alerts: Gun Liability, Subpar Building Codes, Copycat Packaging)

Are There Exceptions?

Yes. The PLCAA has several provisions that allow a company to be sued, including for claims a company has knowingly violated laws related to the marketing of the product related to the shooting.

The Connecticut Supreme Court said in 2019 that the federal law permitted a lawsuit by some of the families of the victims of a 2012 shooting at the Sandy Hook Elementary School. The families sued Remington for violating the state’s marketing law by allegedly promoting its Bushmaster rifle for criminal use. (Supreme Court Allows Sandy Hook Families’ Liability Lawsuit Against Gunmaker)

Remington, which twice filed for bankruptcy during the case, agreed in February to pay the families $73 million, the first settlement of its kind. (Gunmaker Remington to Pay $73M to Settle Liability Claims With Sandy Hook Families)

Also in 2019, the Indiana Court of Appeals said PLCAA did not prevent the city of Gary from pursuing a 1999 lawsuit against firearms manufacturers under the state’s public nuisance laws. Nuisance laws can be used to hold a defendant liable for damage done to a public good, like community safety, and the city alleged the manufacturers knew of illegal handgun sales and failed to prevent them.

Two federal appeals courts, however, have ruled that public nuisance lawsuits are barred by PLCAA because they don’t apply to the sale or marketing of firearms.

Other Legal Cases

Following the Connecticut Supreme Court ruling, other cases were launched that are working their way through the courts, seeking to seize on exemptions in PLCAA.

Victims of a 2019 mass shooting at a California synagogue sued Smith & Wesson, saying the company negligently marketed the AR-15 style rife used by the shooter. A state court judge rejected last year the company’s argument the lawsuit was barred under PLCAA.

Meanwhile, the Texas Supreme Court ruled earlier this year that an online seller of ammunition, Luckygunner.com, was not protected by PLCAA from a lawsuit on behalf of victims of a 2018 shooting at a Santa Fe, Texas, high school. The company is accused of knowingly violating a law that makes it illegal to sell ammunition to minors.

Mexico last year sued Smith & Wesson Brands Inc. and Sturm, Ruger & Co. and other firearm makers for the flood of weapons across the border from the United States. The lawsuit alleges the companies designed, marketed and distributed military-style assault weapons in ways they knew would arm drug cartels, fueling murders and kidnappings.

The companies have argued they cannot be held liable for crimes in Mexico stemming from legal sales of their products in the United States.

The judge overseeing the case in Boston has questioned whether allowing the case to proceed could undermine PLCAA.

Recent Legislative Action

In July, New York’s governor signed into law a measure that allows firearm sellers, manufacturers and distributors to be sued by the state, cities or individuals for creating a public nuisance.

A U.S. judge on Wednesday ruled against the firearms industry which sued to block the law and argued it was barred by PLCAA. (Federal Judge Upholds New York Law Allowing Lawsuits Against Gun Industry)

On Tuesday, California senators approved a bill hours after the Texas shooting that would allow private citizens to sue anyone who manufactures, distributes, transports, imports, or sells assault weapons and untraceable ghost guns. (California Moves Toward Allowing Lawsuits Over Illegal Guns)

The bill, which is supported by Governor Gavin Newsom, is styled on a Texas anti-abortion “vigilante” law that is meant to skirt conflicting federal law. It will now be considered by the state’s assembly.

Lawsuits Challenging Gun Restrictions

Guns rights advocates have also used the courts to challenge firearms restrictions and the U.S. Supreme Court is poised to rule on a case over New York’s limits on carrying concealed handguns in public.

The conservative court appeared at arguments in November ready to strike down the law.

Other lawsuits against restrictions include cases against bans on assault-style weapons in California and Maryland, which challengers say violates the constitutional right to bear to arms.