California Gov. Jerry Brown will decide in the coming days whether to sign controversial measures on immigration and gun control the legislature sent to his desk Tuesday as a contentious session draws to a close.

The legislature sent Brown a bill that would limit the ability of state law enforcement officials to work with federal immigration authorities, the Los Angeles Times reported. The bill would prohibit state and local authorities from turning over anyone arrested for minor offenses to federal authorities for deportation.

State Attorney General Kamala Harris (D) said last year that local authorities didn’t have to comply with the federal Secure Communities program, which requires local officials to share fingerprints of any lawbreakers with federal immigration officials. The new law would prohibit such cooperation.

The legislature also passed its first measures limiting gun ownership and cracking down on so-called “straw purchasers” of firearms. Another bill passed Tuesday would require gun owners to notify authorities of a missing or stolen weapon within a week. The legislature also approved measures to require gun owners to lock firearms when someone who isn’t allowed to possess a weapon is present, and to extend gun safety training requirements to owners of long guns.

The measures are the first California has taken in response to the school shooting at Sandy Hook Elementary, in Connecticut. Despite a national push to pass gun control measures in the wake of the Connecticut tragedy, only a handful of Democratic-controlled states have passed legislation this year.

And if election results in Colorado are any indication, California legislators could face political blowback. On Tuesday, two Democratic state senators who pushed gun control measures in Colorado lost bids to keep their seats, after gun-rights advocates forced recall questions onto the ballot. The National Rifle Association and backers of Mayors Against Illegal Guns, a gun control organization, both spent heavily on the races; the NRA came out on top.

A federal effort to expand background checks passed the Senate, but appears unlikely to come up for a vote in the House.