In the US, of course, it’s more a loophole because marriage is a contract, & contract law is such that as long as the contract is legal at the time it’s written, it continues to be unless otherwise contested.

But as far as I know, this is the first ruling to acknowledge that some transsexuals are already married when they transition, that they choose to remain married after transition, and that their marriage is legally a same-sex marriage after the fact.