Karl Hedberg got custody of his son in 2002 in a divorce in Alexandria, Virginia. But the judge conditioned it on his same sex partner moving out.

The couple sold their house in Virginia and moved to separate apartments in Maryland, a state that is considered to be more gay friendly than the Commonwealth of Virginia.

In 2004 Virginia was no longer the state with continuing exclusive jurisdiction because both parents and the child no longer lived there. Hedberg petitioned the Maryland Court to modify his Virginia custody order because of changed circumstances. The judge denied his request. But the Maryland Court of Special Appeals overturned that decision.

Hedberg was able to present evidence that a one parent home was not in the best interests of his son, now 12 years old, and Judge William J. Rowan III of the Montgomery County Circuit Court agreed. On Monday, he removed the ban from the child custody order.