The Kansas Supreme Court has upheld a state law that gives sperm donors no parental rights unless there is a written agreement.

The court’s decision Friday is the first of its kind in the nation. The case involves Samantha Harrington, the mother of twins who conceived through artificial insemination. She used sperm donated by a friend, Daryl Hendrix.

The mother and donor disagreed on whether there was an oral agreement that created parental rights for the donor. The Supreme Court took up the case, after Hendrix felt he had been denied his right to be a father.

The court held the statue’s requirement of a written agreement was constitutional under both state and federal due process and equal protection provisions.