/ Updated 
By Associated Press

A federal judge has ruled that the U.S. Department of Justice's current system of detaining children with their mothers after they've crossed the U.S.-Mexico border violates an 18-year-old court settlement.

Family detainees walking down the hall at the T. Don Hutto Residential Center in Taylor, Texas, Feb. 9, 2007. The detention facility houses immigrant families awaiting deportation.Charles Reed / Department of Homeland Security via AP file

The decision Friday by U.S. District Judge Dolly Gee in California is a victory for the immigrant rights lawyers who brought the case, but its immediate implications for detainees are not yet clear.

The 1997 settlement bars immigrant children from being held in unlicensed, secure facilities. Gee found that settlement covered all children in the custody of federal immigration officials, even those being held with a parent.

The new lawsuit was brought on by two major detention centers in Texas that are managed by private prison operators. They recently held more than 2,000 women and children between them after a surge in immigrants from Central America.