As a Virginia Senate committee debated how to craft a policy allowing police to take guns away from people deemed dangerous, one Republican made an ominous warning about what could happen if the state starts sending officers up “Ruby Ridge Drive” to bang on the door.

“When they don’t answer the door,” said Sen. Ben Chafin, R-Russell, “… is this committee asking that that door be knocked down to find out what’s on the other side?”

It’s not clear how many of Chafin’s colleagues share his concern about the bill’s potential to create more armed standoffs between homeowners and police. But Democratic lawmakers spent a significant amount of time over the last week fine-tuning the process of how police will interact with people who are subject to court orders temporarily stripping their gun rights.

After two days of heated debate, the state Senate voted 21-19 Wednesday to pass a red flag bill that included several changes adding new layers of due process for those who may be affected. The bill passed the Democratic-controlled Senate on party lines.

Instead of going to homes with a search warrant already in hand to look for guns immediately, the amended bill calls for police to first serve a court order notifying the person they have to relinquish their firearms. If the person refused, the police would have to go back to the court and return with a search warrant. If the person continues to be noncompliant, they could potentially be arrested for violating the order.

“The idea there is that it will sort of de-escalate these situations a little more because you won’t have someone showing up completely unannounced knocking on the door,” Sen. Scott Surovell, D-Fairfax, who presented changes to the bill on the Senate floor Tuesday.

Senate Republicans — who have denounced the bill as an infringement of rights that would let the government take property from people who haven’t been accused of a crime — have made it clear they don’t like the bill in any form.

“We’re going to make them a criminal and say you violated a judge’s order in order to go back and execute a search warrant,” said Sen. Richard Stuart, R-Stafford. “We’ve actually made it worse I think.”

The change to the bill could create a lag time between when police first make contact with a subject and when they have the legal paperwork needed to enter a home and look for guns. The timing, Surovell said in an interview, will depend on how law enforcement wants to proceed if someone refuses to surrender all their guns.

“Could be hours. Could be a couple days,” Surovell said. “Just depends on what the officer does.”

Josh Horwitz, executive director of the Coalition to Stop Gun Violence, said the search warrant process envisioned under Virginia’s bill mirrors the red flag law in Florida, where the concept gained prominence after the 2018 mass shooting at Marjory Stoneman Douglas High School in Parkland. After that shooting, a school safety commission set up by President Donald Trump endorsed the idea of red flag laws.

Horwitz said he has no preference between the bill that passed the Senate and a version still pending in the House.

“I personally have no problem with it whatsoever,” Horwitz said.

As drafted, the House version would allow police to search a home on their initial visit to serve the order. The House has not yet taken up its bill. The legislation will have to pass both chambers and be signed by Gov. Ralph Northam before becoming law.

Seventeen states and the District of Columbia have passed a version of the red flag law.

“‘They have been upheld by courts when they have been challenged on a constitutional basis,” said Sen. George Barker, D-Fairfax, the bill’s patron. “The process that we have set up is actually having very good results in other states.”

Virginia Democrats have been pushing for a red flag law ever since the Parkland shooting, but Republicans refused to give the idea serious consideration.

The red flag bill is one of the more controversial gun-control laws the General Assembly’s new Democratic majorities are pushing for, largely because it’s the only one that actually involves the government taking guns.

On Wednesday, Sen. Amanda Chase, R-Chesterfield, told her colleagues anyone voting for the bill was a “traitor to Virginia.” In response, Sen. Janet Howell, D-Fairfax, said Chase’s comment may have violated the Senate’s rules of decorum.

“I would like her to know that I am deeply offended that she has accused anyone on this floor of treason,” Howell said.

Democrats said they have made a concerted effort in the past week to address concerns raised about the legislation.

“I think we’ve done a real bipartisan effort to make this as solid and defensible as we can while respecting everybody’s rights,” said Sen. Barbara Favola, D-Arlington.

Other due process measures added to the Senate bill would require police to consult with the local prosecutor before petitioning a judge to issue a red flag order. Another change would require law enforcement to give the person subject to the order a copy of the affidavit laying out the facts and evidence the court relied on to issue it.

“We have built so much due process into this thing,” Surovell said.

Lt. Gov. Justin Fairfax and Sen. Joe Morrissey, D-Richmond, were among the Democrats who pressed for due process amendments to the bill.

“The concerns by my friends on the other side were legitimate. They were justified,” Morrissey said during Tuesday’s floor debate. “And they’ve been addressed.”

Morrissey called the red flag law “TDO-lite,” a reference to temporary detention orders used to involuntarily hospitalize people suffering from mental illness who may harm themselves or others. That process, which typically involves recommendations from mental health professionals, also removes a person’s gun rights and requires them to petition a court to have those rights restored.

To issue a substantial risk protection order, a Virginia court would have to find “probable cause to believe that a person poses a substantial risk of personal injury to himself or others in the near future by such person’s possession or acquisition of a firearm.” The court would have to hold a hearing within 14 days to give the person subject to the order a chance to argue their guns should be returned.

Sen. Bryce Reeves, R-Spotsylvania, a former police officer, said he’s had trouble sleeping thinking about situations that could arise from the proposed law.

“You’re going to put officers at risk,” Reeves said. “You’re also going to give officers exigent circumstances to go kick in doors when there’s not really one that exists.”

Defending the bill, Surovell characterized it as a “minor extension” of the numerous laws and policies that allow the government to intervene in Virginians’ lives to ensure public safety.

“If the government has reason to believe that somebody might go out and kill dozens of people, we believe the government ought to be able to go in and get that gun to eliminate that possibility,” Surovell said. “This is not a big step.”