The New York state senate has passed Governor Andrew Cuomo’s Marriage Equality Act by a vote of 33–29. All Democratic senators but Bronx pastor Ruben Diaz Sr. (who spoke vehemently against the measure) voted to support the measure. They were supported by Republicans Roy McDonald and James Alesi, who had announced their intentions to support the bill before the vote, and also Steve Saland, who spoke at length about his decision, and said, “I hope that my parents would be proud.” Mark Grisanti, too, spoke touchingly about his change of heart. The latter group had held out for alterations in the bill designed to offer increased protections to religious groups who object to same-sex nuptials. Those amendments were agreed upon Friday afternoon and passed in the assembly 82–47 in the early evening. Once the bill is signed by the governor, New York will become the sixth and largest state to legalize marriage for gay couples, more than doubling the number of self-reported gay couples allowed to marry in the United States. It joins New Hampshire, Massachusetts, Connecticut, Iowa, Vermont, and the District of Columbia, which variously legalized marriage equality through the legislatures and through court rulings.

Cuomo’s updated bill, which grants same sex couples the same legal rights as heterosexual couples, will go into effect 30 days after it is signed into law.

In recent months, marriage equality became one of Governor Cuomo’s signature issues, along with a property tax cap and ethics reform. Cuomo reached a deal on the last earlier this month. The former, the property tax cap, became entwined with the renewal of rent regulations in a last minute omnibus bill that required intense negotiation.

As the legislative session wound down, tensions flared over the rights of gays to marry. Advocates from both sides, like the united gay groups Marriage Equality New York, the Empire State Pride Agenda, Freedom to Marry, the Log Cabin Republicans, and the Human Rights Campaign, as well as conservative groups and leaders like Catholic Archbishop Timothy Dolan. Since Monday, the halls outside of the Senate chamber have been filled with protesters on both sides chanting and singing. At points, state troopers had to rein in the chaos.

A few Republican senators had indicated that their votes were up in the air as the spring progressed. When, last week, Alesi and McDonald indicated their votes had changed and Governor Cuomo secured the pledge of three previous Democratic “no” votes, the supportive vote tally was left one short. As this week progressed, it seemed increasingly possible that Skelos and the Republicans would block a vote on the issue at all. Tensions remained high until changes protecting religious groups were agreed upon in both houses, and Skelos agreed to finally put the matter to a vote late Friday. He said at the time that members were free to “vote their conscience,” his original pledge months ago, from which he’d recently strayed. The result indicates that most of the senators did exactly that.

Related: Trailblazing: A History of Gay Rights in New York

Gay Marriage All Goes According to Andrew Cuomo’s Plan