A Spanish judge who ordered a mother to choose between her partner and her daughters, because “a homosexual environment threatened their education,” is under investigation.

The woman, from Murcia, south east Spain, was faced with the impossible choice after her husband discovered her in a compromising position with another woman.

He filed for divorce and was awarded custody of the couple’s two daughters, after ‘proving’ his wife is a lesbian.

“The mother will have to chose between her daughters and her new partner,” said judge Fernando Ferrin in a ruling last month, according to typiallyspanish.com

“It’s impossible that two homosexual parents can give a child complete education.”

The Spanish Federation of Gays, Lesbians, Transsexuals and Bisexuals said the case went against basic human rights:

“There has been no case of it’s kind since the arrival of legal gay marriage in Spain, and the law states that the custody of a child should be decided independently of the sexual orientation of the parent.”

Murcia’s Supreme Court has now started disciplinary proceedings against Judge Ferrin, known for his firm stance against topless swimming and nudists.

He is also under investigation for stalling a lesbian step-mother’s attempts to adopt her partner’s child.

“It is the homosexual environment which is prejudicial to children, and notably increases the risk that they too become homosexual,” he said.

Spain is credited with having some of Europe’s most liberal gay rights legislation, and in 2005 became the third country to legalise gay marriage.

However, decades of persecution under dictator Francisco Franco ended with the decriminalisation of homosexuality in 1979.