The Massachusetts Senate voted Thursday to join 17 other states in protecting transgender people from discrimination when accessing public accommodations like lockers rooms and lavatories. At the end of a lopsided debate, only four Republican senators objected to the bill. GOP amendments seeking to add penalties for abusing access rights were rejected by the Democratic majority.

"No one deserves to be discriminated against for who they are—period," Sen. Sonia Chang Diaz (D-Boston) a lead supporter of the bill, said.

With Senate passage, the debate now moves to the House, where some moderate and conservative members are leery of codifying transgender access at the expense of the privacy or comfort of others. House Speaker Robert DeLeo wants a super majority to pass the bill to avoid a possibly veto from Gov. Charlie Baker —who won't say one way or the other if he'll sign or veto.

Much of the Senate's debate centered around punishment for sexual predators who try to use the law to get into private spaces for unlawful reasons. Sexual assault and peeping are of course already illegal, but Republicans in the Senate wanted to make sure the bill laid out more specific processes and penalties for anyone posing as transgender in order to commit a crime.

The bill comes after a slew of more conservative states have passed laws limiting the rights of LGBT individuals to access public accommodations. Democrats in Massachusetts wanted to combat those efforts.

"Make no mistake, at the center of those policies are real people whose real lives and real livelihoods are being destroyed by bigotry," Chang-Diaz said.

"In Massachusetts we are civil rights pioneers by nature," Chang-Diaz said when introducing the bill. "It is in our cultural DNA. and that's why it's particularly difficult to fathom how it is that in 2016 we are still fighting for public accommodations and full equality for transgender bay staters. Public accommodations are fundamental to equal rights in our society."

Sen. Vinny deMacedo (R-Plymouth) offered an amendment that would have excluded locker rooms from the antidiscrimination rules as a compromise to address one of the more sensitive parts of the public transgender debate, some people's discomfort at the idea of a transgender man or woman undressing or showering near them.

The amendment was soundly defeated.

"The discomfort of any individual pales in comparison to the to the prejudice and pain that our transgender community has endured and endure and endured for years," Sen. Harriet Chandler said.

After the vote, Massachusetts Family Institute president Andrew Beckwith told WGBH News the Senate Republican caucus chose to concentrate on amendments to address safety concerns instead of denouncing the general concept of the bill. Beckwith said Republicans know how "radicalized" the Senate has become and that Rosenberg has ignored the voices of women threatened by those who may abuse access rights.