One day after a mass shooting in California left 14 people dead, Republican lawmakers in New Jersey declined on Thursday to override Gov. Chris Christie’s veto of a gun-control bill they had unanimously supported in June.

Democrats in the State Assembly invoked the bloodshed on Wednesday to shame Republicans into joining them in overriding the bill, which would require the police to be notified when someone wants to expunge a mental-health record for the purpose of buying a gun. The bill had passed both houses of the State Legislature without a dissenter before Mr. Christie, a Republican who is running for president, vetoed it.

Mr. Christie has been campaigning frequently in Iowa and New Hampshire, where voters generally support the right to own guns. He has tried to distance himself from New Jersey’s relatively tough gun laws, but Democrats have responded by saying that he is out of step with his constituents.

The State Senate president, Stephen M. Sweeney, a Democrat from Gloucester County who is considered a likely candidate to succeed Mr. Christie, said the governor was “the only person that objected to this bill.” That remark came after the Senate voted in late October to override the veto, the first successful attempt to undo one of Mr. Christie’s vetoes in more than 50 tries.