The Supreme court ruled it's completely legal in Obergefell vs Hodges in 2015. It's a crying shame it had to be codified in 2022.
again the constitution does not define or protect gay marriage. Todays supreme court would recognize that and push it back to the states to decide as they did Roe vs Wade.
at that point it would either be a state by state issue or it would have to be codified by congress.
Its not a shame that it has to be codified its constitutionally the correct answer for congress to legislate law to protect rights not defined by the constitution that over time the majority decides should be granted.
This supreme court is forcing Congress to do their job.