(CNN) Lawmakers in Texas just approved a bill that will allow licensed gun owners to carry handguns in public for up to a week following a natural disaster.

It squeaked through the Senate 16-15. Now it's heading to Gov. Greg Abbott's desk, as lawmakers close out this year's legislative session.

According to a summary , bill supporters don't want to be "forced to leave handguns behind in vehicles or homes, where they could be at risk from looters."

The bill, which has the backing of the National Rifle Association , grants immunity to gun owners without conceal carry permits to keep their weapons with them when fleeing disaster areas.

In the floor debate, Creighton said that following Hurricane Harvey, Gov. Abbott issued evacuation orders for effected areas on August 23, 2017, and that "mandatory and voluntary evacuations were ongoing through the 28th of August." He said that lawmakers felt a full week was necessary for gun-owners to evacuate a disaster area and to find a safe place to stay.

He added that the bill doesn't require relief shelters to admit those carrying handguns, and shelters in the state can make their own rules around guns, including "checking them and storing them," when people take refuge.

According to a fiscal note attached to the bill, the state currently punishes those who carry weapons illegally by a misdemeanor or felony based on the type of offense. The bill wouldn't cause a "significant fiscal impact" to the state because it wouldn't add to the burden on prison facilities, the note says.

Legislators sent the bill back and forth between bodies before narrowly passing it

After the original bill carried in the House, the Senate amended the bill to narrow the window for carrying a concealed handgun to 48 hours after a mandatory evacuation order, rather than a more general disaster declaration. The Senate easily passed their new version 23-8

But when the Senate's take on the policy got kicked back to the House, representatives stood their ground, and passed a version 91-52 that kept the week-long period and expanded the grace period back to apply following natural disasters, even if a mandatory evacuation hadn't been ordered.

And last night, the House version managed to clear the Senate as well.

While support for the bill largely fell along party lines, Republican Sen. Joan Huffman joined two other GOP Senate members in opposing it.

During the floor debate, Huffman said the bill amounted to "permitless carry, open and concealed," and that the latest Senate version was being rushed through the body as this year's legislative session was about to close.

In opposing the bill, she cited "strong law enforcement objection" to the bill from "individuals who didn't have an opportunity" to voice their objections. She called it "poor public policy that's not well thought out." Noting that she was "as pro-Second Amendment as anyone," she said she felt that the policy was "not solving a problem, it is creating a problem."

The new law takes effect September 1, 2019.