BUFFALO, N.Y. -- The Respect for Marriage Act will require that all states recognize marriages legally performed in other states.

U.S. Rep. Brian Higgins, a co-sponsor of the bill, said there was concern the U.S. Supreme Court could strike down previous precedent, allowing states to impose bans.

"The best way to protect against efforts to tear down marriage equality is to enshrine it in federal law and that's what Congress did," Higgins said.

The House of Representatives passed an earlier version of the bill in July but the Senate delayed its vote until after the midterm election, approving its bill last week. Amended legislation passed the House again Thursday with some bipartisan support.

"The main factor was so many of our Republican elected officials reaching across the aisle and becoming more public, putting their names on this bill and eventually supporting it," Stonewall Democrats of Western New York President Bryan Ball said.

Ball said it comes at a crucial time with growing fear the Supreme Court could overturn the 2015 Obergefell decision, which guarantees same-sex couples the fundamental right to marry, following the court's June decision overturning abortion rights.

"These victories are victories that never should have been something that had to be won. The fact that we're standing here talking in 2022 about how the federal government is going to act to protect rights for LGBTQ families and interracial families, that's something that never should have been a question," Ball said. "That never should have been involved in the political arena at all."

In the hypothetical scenario in which Obergefell is stuck down, Ball said states like New York where marriage equality is already codified could become crucial.

"That would not prevent them from going to other states, getting married and then being recognized in those states that have the bans so that's something that this legislation fortunately and very aptly took into consideration," Ball said.

He said the congressional action is far more than symbolic as same-sex couples have a long-justified fear their rights could be taken away.

"Marriage Equality, it protects virtually everything that you interact with the government for in terms of taxes, benefits, social security."