The Texas Legislature will make a final vote Wednesday on a bill that will let county judges and other elected officials recuse themselves from issuing marriage licenses if they have personal religious objections.

Senate Bill 522, authored by state Sens. Charles Perry (R-28) and Brian Birdwell (R-22), received preliminary approval in the Senate 21-10 on Tuesday. The final vote on the bill is expected for Wednesday. The bill will still allow marriage licenses to be issued, just by another official without any religious objections.

"If we don't do this, we are discriminating against people of faith," Birdwell told the Associated Press. He was referring to clerks, judges, justices of the peace and other elected officials empowered to issue marriage licenses in Texas' 254 counties.

Since the Texas Legislature meets every two years, this is the first time lawmakers have been able to respond to the U.S. Supreme Court’s 2015 decision that legalized gay marriage in the United States.

Opponents to SB 522 say it defies the nation’s highest court and sanctions discrimination.

"The Texas Senate today said it has no problem with public officials picking and choosing which taxpayers they will serve," Kathy Miller, president of the progressive activist group the Texas Freedom Network, said in a statement. "This bill opens the door to taxpayer-funded discrimination against virtually anyone who doesn't meet a public official's personal moral standards."

State Sen. José Menéndez (D-26) is among those who believe the legislation will open Texas to more lawsuits.

“Our fundamental obligation -- Senator Menendez -- I believe is to protect both rights. The right to the couple that wants to get married based on the Obergefell decision, and the right of conscience as explicitly expressed in both the United States Constitution and Article 1, Section 4 of the State Constitution. This bill protects both,” Birdwell said.

“The spirit of this bill is exactly what someone like me needs. I've had numerous threats and lawsuits. My wife had to drive another car because media and people who opposed my position were following us around, trying to intimidate us and scare us just going to Kroger in our community,” said Dallas County Judge Bill Metzger.

Other lawmakers have pointed out the positions – such as judges and clerks who issue marriage licenses – are elected by the people. They argue there is no room in government on the ground of religion, because of the separation of church and state that the governing body agrees to.

The Associated Press reported Birdwell's proposal only applies in cases where other officials without objections agree to step in for the recusing party. If the substituting official is located outside the county where the marriage license is being sought, documents could be sent electronically so as not to unduly delay the process.

TAP HERE to follow the progress of SB 522.

The Associated Press contributed to this report.