Gov. Bruce Rauner signed a bill into law on Friday banning the gay panic and trans panic defense in murder cases, making Illinois the second state to do so, after California.

The law prevents people in the state from claiming the murder victim was gay or bisexual and made a sexual advance that caused them to react violently, or that the victim’s gender identity caused the same.

The American Bar Association has come out against the gay and trans panic defense, and urged local, state, and federal governments to pass legislation banning it.

Rauner also signed a bill into law making it easier for transgender and intersex individuals to change the gender marker on their birth certificate.

Those wishing to change their gender marker will no longer be required to submit a sworn affidavit from a physician confirming gender confirmation surgery, instead only requiring a physician to state “clinically appropriate” treatment has been provided.

“Today, our state is a fairer and more inclusive place for all people,” Christopher Clark, the Midwest Regional Director for Lambda Legal, said in a statement. “Transgender and intersex people born in our state will now have easier access to important identity documents that are necessary to work, travel, obtain vital benefits, and most importantly, navigate the world a little safer. By eliminating the surgical requirement, we now have a better law that is in line with medical standards of care, and puts important and very personal health care decisions in the hands of individuals and their health care professionals — where they belong.”

“‘Gay panic’ and ‘trans panic’ defenses rely on anti-LGBT bias and reinforce it, perpetuating a vicious cycle of violence against our communities,” Clark added. “LGBT people, especially transgender women of color, are more likely to be victims of violent crime. We look to courts for justice, not to put victims on trial. We hope that other states will take Illinois’ example and do the same.”