HOUSTON (AP) — The attorney taking on President Donald Trump over his alleged affair with an adult film actress has appeared in Houston immigration court to try to secure the release of a 9-year-old boy from Guatemala.

michael avenatti 1006311382 Stormy Daniels Lawyer Appears In Texas Immigration Court

Attorney Michael Avenatti (David McNew/Getty Images)

A judge on Tuesday denied Michael Avenatti’s request to dismiss the case against the boy.

Avenatti and another attorney, Ricardo de Anda, had offered to take the child from court to the airport and fly him to Guatemala, where his mother was deported in June.

Instead, the judge ordered the boy to be removed once his case is formally processed by the government, which could take several weeks.

In addition to his legal fights on behalf of actress Stormy Daniels, Avenatti has taken up the cases of immigrant families separated under the Trump administration’s zero-tolerance policy.

(© Copyright 2018 The Associated Press. All Rights Reserved. This material may not be published, broadcast, rewritten or redistributed.)