BOSTON >> Advocates for transgender people in Massachusetts say they can no longer be legally discriminated against in public places.

A new law that took effect Saturday bars discrimination on the basis of gender identity in public accommodations. Key provisions of the law allow transgender people to use bathrooms and locker rooms that correspond to their gender identity.

The Democratic-controlled Legislature approved the bill after several years of debate. Republican Gov. Charlie Baker signed it into law in July.

Mason Dunn, co-chair of Freedom Massachusetts, a group that advocated for the new law, said the protections represent a "shining moment" in Massachusetts' legacy as an "inclusive, welcoming place."

The group says Massachusetts is the 18th state to provide similar protections for transgender people.

But not everyone is happy with it. The Massachusetts Family Institute is hoping to put a question before voters on the November 2018 ballot calling for repeal of the measure.

Attorney General Maura Healey and the Massachusetts Commission Against Discrimination recently issued guidelines to businesses for complying with the law.