New York (CNN) New York became the sixth state to ban the so-called gay and trans "panic" defense Sunday, as millions of revelers celebrated WorldPride in Manhattan.

Gov. Andrew Cuomo at the 2018 New York City Pride March

The panic defense asks a jury to find that a victim's sexual orientation or gender identity is to blame for a defendant's violent reaction, including even murder.

"New York has always been the home of the LGBTQ equality movement, always," said Gov. Andrew Cuomo, signing the ban into law. "It all started here. It started at Stonewall. It started when we hosted the first Pride Day ever. And we've kept that legacy alive. This is the leading State in the United States of America for LGBTQ equality."

New York follows California, Rhode Island, Illinois, Nevada and Connecticut to pass such a law.

Signing the legislation was "the best way to kick off the #PrideNYC march," Cuomo tweeted.

I just signed legislation banning the repugnant "gay/trans panic" legal defense in New York State.



The best way to kick off the #PrideNYC March! pic.twitter.com/8L8avDkbfm — Andrew Cuomo (@NYGovCuomo) June 30, 2019

Read More