ALBANY, N.Y. (AP) — A midlevel court has rejected a challenge to New York’s new gun law, dismissing arguments it was pushed through the state Legislature improperly and that its restrictions violate the Second Amendment.

The four Appellate Division justices say they agree with a trial judge that the law’s chief provisions don’t violate the Second Amendment right to bear arms.

Those provisions ban large-capacity magazines and prohibit sales of some guns newly classified as assault weapons while requiring registration of such firearms that New Yorkers already own.

The court on Thursday also upheld Gov. Andrew Cuomo’s use of a special message permitting the Assembly and Senate to vote soon after the bill was introduced, without waiting the usually required three days.

Earlier this week a federal appeals court upheld New York’s gun law.