Get breaking news alerts and special reports. The news and stories that matter, delivered weekday mornings.

MADISON, N.C. — Remington, the gun maker beset by falling sales and lawsuits tied to the Sandy Hook Elementary School massacre, has reached a financing deal that would allow it to continue operating as it seeks Chapter 11 bankruptcy protection.

The maker of the Bushmaster AR-15-style rifle used in the Connecticut shooting that left 20 first-graders and six educators dead in 2012, said Monday that the agreement with lenders will reduce its debt by about $700 million and add about $145 million in new capital.

The company was cleared of any wrongdoing in the shooting, but investors repulsed by the massacres distanced themselves from the company's owner, investment firm Cerberus Capital Management. Cerberus acquired the gun maker in 2007, just when gun sales began to skyrocket.

Firearm background checks, a reliable barometer of gun sales, had risen steadily for at least a decade.

Let our news meet your inbox. The news and stories that matters, delivered weekday mornings. This site is protected by recaptcha

Firearms training unit Detective Barbara J. Mattson, of the Connecticut State Police, holds up a Bushmaster AR-15 rifle, the same make and model of gun used by Adam Lanza in the Sandy Hook School shooting, during a hearing of a legislative subcommittee in Hartford, Connecticut on on Jan. 28, 2013. Jessica Hill / AP file

That changed last year with the election of President Donald Trump, and it has taken a toll on the gun industry.

Gun sales spike on the election of candidates who are perceived to be more likely to pursue more stringent gun control laws, whether or not there is any truth in that perception.

The opposite has occurred since Trump was elected. He became the first sitting president to address the National Rifle Association in three decades, telling members at their annual meeting last spring, "You have a true friend and champion in the White House."

Related: Fate of Sandy Hook lawsuit against gun maker could be decided by a slingshot

Firearm background checks declined faster in 2017 than in any year since 1998, when the FBI first began compiling the data.

While Remington is not a publicly traded company, shares in rival Sturm, Ruger & Co. slid almost 3 percent Monday. It's shares have fallen almost 14 percent this year.

Remington Outdoor Co., the nation's oldest gun maker, will attempt to file a prepackaged reorganization plan with the U.S. Bankruptcy Court of Delaware under Chapter 11 of the bankruptcy code.

The company, based in Madison, North Carolina, did not respond to attempts by The Associated Press to contact the company about the timing of bankruptcy procedures.