The Arizona State Senate approved a bill Wednesday to allow business owners to refuse service to gay people by citing “sincerely held” religious beliefs. The Republican-sponsored bill passed 17-13 along party lines.

Democrats objected to what they called a legal justification for discrimination, the Arizona Daily Star reports. SB 1062’s supporters just defeated a different measure that would extend employment protections to sexual orientation.  

“The bill opens the door for discrimination against gays and lesbians,” said Sen. Steve Gallardo, a Democrat from Phoenix.

But Sen. Steve Yarbrough, a Republican from Chandler, says the bill is to protect people’s rights.

“This bill is not about discrimination,” Yarbrough said. “It’s about preventing discrimination against people who are clearly living out their faith.”

“We all have the right to our religious beliefs,” Gallardo maintained. “But I do not agree that we have the right to discriminate because of our religious beliefs. I do not believe we have to throw our religious beliefs to others that don’t share our same beliefs.”

Gallardo proposed that businesses that want to refuse gays based on their religious beliefs put up signs to indicate their policy.

“If there is an organization or a business out there that wants to use the defense of religious freedom, I believe that consumers have a right to know,” Gallardo said.

The Republican majority struck down the amendment.

Other opponents of the bill fear that it will be bad for business and that it will go too far in denying people basic services based on anything a proprietor doesn’t agree with.

But Yarbrough stood by his First Amendment argument.

“I understand that the freedom of religion can be inconvenient,” he said. “But this is what our Constitution contemplates.”

The Arizona house is due to vote on a similar measure in the coming days.

BuzzFeed reports that four other states, South Dakota, Kansas, Idaho, and Tennessee, passed similar measures on Tuesday.

Sources: Arizona Daily Star, BuzzFeed