The gunman who fatally shot at least 12 people at a bar in California on Wednesday reportedly used a gun equipped with a high-capacity ammunition magazine to carry out his attack. Two years ago, Californians worried about such rampages voted for a ballot proposition intended to remove devices like it from circulation in the state. But a federal judge blocked the measure from taking effect.

In June 2017, Judge Roger Benitez of the Southern District of California issued a temporary injunction preventing the state from enforcing the new law, which would have required gun owners to rid themselves of any magazine with a capacity of more than 10 rounds. The order arrived just two days before the ban was to take effect and resulted from a lawsuit brought by gun owners in San Diego County and the California Rifle & Pistol Association, an affiliate of the National Rifle Association.

It has been illegal to sell or transfer a high-capacity magazine in California since 2000, and it may never be known how and when the Thousand Oaks gunman acquired his. But Benitez’s ruling has drawn renewed scrutiny in the wake of Wednesday’s attack.

A growing body of evidence shows that high-capacity magazines can sharply increase the body count during a shooting by allowing gunmen to squeeze off more shots before having to stop to reload. Mother Jones examined 62 mass shootings between 1982 and 2012 and discovered that half of them involved magazines with more than 10 rounds. A subsequent study relying on the same dataset found that mass shootings involving high-capacity magazines produced 60 percent more fatalities and more than three times as many victims with nonfatal gunshot wounds.

In the 1999 massacre of 13 people at Columbine High School, one of the shooters used magazines that allowed him to unleash dozens of rounds before having to reload. More recently, high-capacity magazines were used in the mass shootings at a movie theater in Aurora, Colorado, an elementary school in Newtown, Connecticut, a nightclub in Orlando, Florida, and a country music festival in Las Vegas, just to name a few. Law enforcement records in multiple cities show that high-capacity magazines are disproportionately found in guns linked to violent crimes.

The correlation between high-capacity magazines and mass carnage has made them a target of regulators. Until it expired in 2004, the Federal Assault Weapons Ban prohibited manufacturing magazines capable of holding more than 10 rounds, but allowed owners to retain those already in circulation. Nine states and more than a dozen municipalities have instituted their own limits on magazine size.

The research on the efficacy of such controls is limited — and the studies that do exist show mixed results. An analysis by The Washington Post found that the number of high-capacity magazines recovered by Virginia police dropped during the 10-year federal ban on the devices, only to rise once it was lifted. Meanwhile, The Trace reported last year that the number of high-capacity magazines recovered by Baltimore police actually increased after Maryland banned them in 2013, though experts noted that, because the law grandfathered in existing devices, it would likely take more time to see their circulation drop off.

In 2000, California banned the manufacture, importation, and sale of magazines capable of holding more than 10 rounds; like similar federal and state statutes, it allowed people already in possession of the devices to keep them. Police had trouble enforcing the mandate: Even if officers found a gun owner in possession of a high-capacity magazine, they had no way of knowing when it was purchased. And online videos show how simple it is to hack some magazines sold as holding 10 rounds and expand them to accept three times that using a basic hand drill.

In December 2015, a husband and wife armed with 30-round magazines killed 14 people in San Bernardino. The following year, voters approved a ballot initiative expanding the law to prohibit possession of the devices. The new rules gave people who owned high-capacity magazines until July 1, 2017, to transfer them out of state, sell them to a licensed dealer, or surrender them to law enforcement. Anyone caught with an illegal magazine after that deadline would have faced fines and misdemeanor criminal charges.

For gun-rights supporters, the ban was a manifestation of their worst fears: government confiscation of weapons. The California Rifle & Pistol Association teamed up with gun owners to sue California Attorney General Xavier Becerra and seek an injunction prohibiting law enforcement from enforcing the ban until the lawsuit was settled.

Judge Benitez, a George W. Bush appointee, came down on the side of the gun owners, writing that the criminalization of high-capacity magazines was likely unconstitutional. The state Attorney General’s Office fought to have the injunction overturned by the Ninth Circuit Court of Appeals, but lost, with the panel ruling by a 2-1 vote this summer that Benitez’s decision could stand. The state of California could thus be legally blocked from forcing gun owners to get rid of their high-capacity magazines until the underlying lawsuit – Duncan v. Becerra – is resolved.