FRANKFORT — Moments after Senate Republicans and Democrats finished congratulating each other Thursday on their bi-partisanship on anti-heroin legislation, a fierce debate erupted along party lines over the contentious legislation known as Right To Work.

The high-priority piece of legislation for the Senate’s Republican leadership passed out of committee in a flash Wednesday night—and it passed out of the Republican-controlled Senate Thursday mostly along party lines, with only one dissenting Republican and one absent member.

The legislation allows employees to work for businesses with organized labor without having to pay union dues.

Senate President Robert Stivers, a Manchester Republican, said the bill isn’t anti-union, only that it’s main goal is to prevent companies from forcing employees to join a union.

“An individual where a collective bargaining agreement has been struck, can come in and work and not be compelled, forced or asked to pay these in-lieu-of fees, charitable contribution dues, or a joining of a union,” Stivers said.

But Democrats rose one after the other to fight against the measure, starting with state Sen. Reginald Thomas, a Lexington Democrat who argued that states with Right To Work laws see a significant drop in how much workers are paid. Thomas cited a 2012 report by the non-partisan Congressional Budget Office.

“What they report is this: if you compare the wages in Right to Work states to those wages in non- Right to Work states, what you’ll find is that the wages in non-Right to Work states are over $,7200 more than the wages in Right to Work states,” Thomas said.

Sen. Damon Thayer, a Georgetown Republican and the majority floor leader, fired back with stories about a family member who was required to join a union, and how corporate jobs from a northern Kentucky Toyota facility were moved to Texas, a Right to Work state.

He then tackled job-creation. “We all know from public polling it’s the top issue of the minds of most Americans,” Thayer said. “And my response is simple: It is not the job of government to create jobs. That’s for the private sector.”

Expectations are low that the bill will pass the Democratic-controlled House, but it’s headed there all the same after clearing the Senate 24-12.