A court in Thailand on Tuesday named a wealthy Japanese man the legal parent and sole guardian of 13 surrogate children he fathered, Reuters reported.

The case of the surrogate babies came to light in 2014 when the police said they found 16 babies the man fathered with surrogate mothers in Thailand, BBC reported.

The 28-year-old son of a wealthy Japanese entrepreneur had petitioned the court for custody in 2015, and appeared via video conference to testify in the case earlier this month, AP reported.

The court gave the man “sole parent” rights after the Thai surrogates forfeited their rights. The court did not reveal the man’s name during the hearing.

“For the happiness and opportunities which the 13 children will receive from their biological father, who does not have a history of bad behaviour, the court rules that all 13 born from surrogacy to be legal children of the plaintiff,” Bangkok’s Central Juvenile Court said. The man was awarded custody of his other three children in 2015.

The court accepted lawyer Kong Suriyamontol’s argument that the man simply wanted a very large family, and that with his wealth, he will be able to look after the children well, BBC reported. Thai officials also told the court they visited Cambodia and Japan and found the man had enough facilities to bring up the 13 children.

The children are still in state custody, and the man is in talks with the Social Development and Human Security Ministry about the next steps. His lawyer said the man plans to raise the 13 children – all four-years-old – in Japan.

The ‘baby-factory’ case

After details of this case, which came to be known as the “baby factory” case, were revealed in 2014, the man was investigated by Interpol for human trafficking.

His Bangkok apartment was raided and the police found nine surrogate babies, nannies and a pregnant surrogate mother.

The scandal also led authorities to crack down on Thailand’s unregulated surrogacy business. In 2014, there were also allegations that an Australian couple abandoned their Down Syndrome baby with his Thai birth mother, taking only his healthy twin sister back to Australia.

In 2015, commercial surrogacy was banned in the country.