BOISE, Idaho -- Aerial fireworks will no longer be legal to sell to the public in Idaho, according to an Idaho Attorney General's Office opinion announced Tuesday morning.

The opinion effectively closes a loophole that allowed the sale of aerial fireworks as long as the purchaser signed an agreement saying he or she would not set them off in the state limits.

Fire chiefs have long opposed the loophole, arguing it is ineffective at actually stopping people from setting off illegal fireworks, and leads to dangerous and expensive human-set fires like the 2,500-acre blaze Table Rock Fire, which was started with an illegal firework last summer.

The AG's opinion directs retailers to immediately remove the illegal aerial fireworks from their shelves. Aerial fireworks for a public display, like the kind hosted by the City of Boise, will still be allowed with the proper permit.

The opinion does not apply to tribal land.

“Special fireworks, that is, fireworks that are not non-aerial common fireworks or ‘safe and sane’ fireworks, can only be sold to a person possessing a permit issued pursuant to Idaho Code 39-2605 for a public display or event," Deputy Attorney General Paul Panther wrote. "Such fireworks can only be sold within a reasonable time period before the display or event.”

The decision follows a failed attempt during the 2017 Idaho legislative session to outlaw the sale of aerial fireworks in the state. Boise Rep. Mat Erpelding sponsored the bill, but it was shot down by members of the House State Affairs Committee.

The fireworks opinion was issued in response to Erpelding's inquiry.

“I stand by Idaho’s fire chiefs who are working to prevent these costly and unnecessary wildfires which jeopardize the lives of our citizens and first responders, destroy our public lands and cost taxpayers hundreds of thousands of dollars in wasted money," Erpelding said in a statement Tuesday.

Boise Fire Chief Dennis Doan, who had been an outspoken supporter of the change said he was "outraged" at the bill's failure, also lauded the AG's opinion.

“This clarification from the Attorney General’s office makes it clear that the sale of aerial fireworks to the general public is not allowed in Idaho," he said in a statement. "I, along with The Idaho Fire Chiefs Association, know that keeping aerial fireworks from being sold in Idaho to the general public will further protect citizens, their property, and our firefighters who risk their lives battling fires caused by aerial fireworks.”