Updated

California lawmakers approved a bill this week that would expand the list of people who could ask a court for a gun violence restraining order, reports said.

AB2888 passed the state Senate 25-12. It would allow co-workers and school personnel to petition a court to temporarily remove guns from someone they believe poses a danger, the San Francisco Chronicle reported.

The legislation would build on the state's existing "red flag" law, passed in 2014 following a deadly shooting in Isla Vista that resulted in seven deaths, including the shooter, the Huffington Post reported. The law went into effect in 2016.

But critics say that expanding the gun-takeaway law could lead to abuses, the Chronicle reported.

"It is very dangerous when you go after someone's liberty for some perceived security," Craig DeLuz of the Firearms Policy Coalition told Sacramento's KCRA-TV.

"It is very dangerous when you go after someone's liberty for some perceived security."

— Craig DeLuz, Firearms Policy Coalition

"We all want to do what we can to make sure we keep firearms out of the hands of individuals who can potentially be a danger to themselves or others," he said. "But in any case, we must always be careful of violating civil liberties."

Currently, the red flag law can be used only by immediate family members, roommates and law enforcement, according to reports.

The expansion bill sponsored by Assemblyman Phil Ting, D-San Francisco, now heads to Gov. Jerry Brown, who vetoed a similar proposal in 2016, one that Ting filed following a mass shooting in San Bernardino, the Huffington Post reported.

Brown said then it was “premature to enact a further expansion," the report said. It was not immediately clear whether the governor would sign the latest bill, according to the Chronicle.

“This is about getting guns out of the hands of the wrong people," Ting said.

“This is about getting guns out of the hands of the wrong people."

— Assemblyman Phil Ting, D-San Francisco

Under the bill, a judge could bar a person from possessing a gun for as long as a year, the report said.

In a tweet, Ting called it "another tool to protect communities."

Right now, if a judge grants a restraining order, "the gun owner is required to surrender his or her firearms for 21 days while awaiting a hearing on whether the order will be extended for a year," the Chronicle reported. The person would be barred from buying firearms or ammunition during that time.

“We’re grappling with this issue of gun violence as a nation,” Ting told the Post. “I’ve never said this is a panacea, but it’s just one of many solutions we have to offer.”

The assemblyman said his bill would provide additional opportunities to catch troubling behavior.

"You don't have to increase the restrictions on people in general to get firearms away, but actually be able to do something that targets dangerous people," Amy Barnhorst, a psychiatrist at the University of California at Davis, told Sacramento's KCRA-TV.

“If you can just stop people at that point where they try to get a gun they can't become mass shooters," she said.