McALLEN, Texas (AP) — The Trump administration is seeking to end an immigration policy cornerstone that since the 1990s has offered protections to child migrants in federal custody, a move that will be challenged by advocates, according to a court filing Thursday.

The protections in place, known as the Flores Settlement, largely limit to 72 hours the amount of time that child migrants traveling alone or with family and detained by the U.S. Border Patrol. They also ensure the children are kept in safe and sanitary conditions.

President Donald Trump tried to end the protections during his first term and his allies have long railed against it. The court filing, submitted jointly by the administration and advocates, says the government plans to detail its arguments later Thursday and proposes a hearing on July 18 before U.S. District Judge Dolly Gee.

The settlement is named for a Salvadoran girl, Jenny Flores, whose lawsuit alleging widespread mistreatment of children in custody in the 1980s prompted special oversight.

In August 2019, the first Trump administration asked a judge to dissolve the agreement. Its motion eventually was struck down in December 2020 by the 9th U.S. Circuit Court of Appeals.

Under the Biden administration, oversight protections for child migrants were lifted for the U.S. Department of Health and Human Services after new guidelines were put in place last year.

The Department of Homeland Security is still beholden to the agreement, including Customs and Border Protection, which detains and processes children after their arrival in the U.S. with or without their parents. Children then are usually released with their families or sent to a shelter operated by HHS, though processing times often go up when the number of people entering increases in a short time period.

Even with the agreement in place, there have been instances where the federal government failed to provide adequate conditions for children, as in a case in Texas where nearly 300 children had to be moved from a Border Patrol facility following reports they were receiving inadequate food, water and sanitation.

Court-appointed monitors provide oversight of the agreement and report noncompliant facilities to Gee. CBP was set to resume its own oversight but in January a federal judge ruled it was not ready and extended the use of court-appointed monitors for another 18 months.

FILE - In this March 30, 2021, file photo, young unaccompanied migrants wait for their turn at the secondary processing station inside the U.S. Customs and Border Protection facility, the main detention center for unaccompanied children in the Rio Grande Valley, in Donna, Texas. (AP Photo/Dario Lopez-Mills, Pool, File)

Credit: AP

icon to expand image

Credit: AP

FILE - In this March 30, 2021 file photo, minors lie inside a pod at the Donna Department of Homeland Security holding facility, the main detention center for unaccompanied children in the Rio Grande Valley run by U.S. Customs and Border Protection (CBP), in Donna, Texas. (AP Photo/Dario Lopez-Mills,Pool, File)

Credit: AP

icon to expand image

Credit: AP