A federal judge has blocked President Donald Trump’s administration from using billions of dollars in Pentagon funds for the construction of the border wall.

In his decision, Senior U.S. District Judge David Briones, who was appointed by former President Bill Clinton, said Tuesday the administration cannot use military construction funds to build more barriers on the southern border.

In September, Secretary of Defense Mark Esper OK’d diverting $3.6 billion in military construction funds for 11 wall projects on the border with Mexico. The Pentagon said half the money was coming from deferred projects overseas, and the other half was planned for U.S. projects.

Trump’s declaration of national emergency to speed up construction was ruled unlawful.

Read the ruling below:

The suit, which was brought by El Paso County, Texas, and Border Network for Human Rights, argued Trump overstepped his bounds when he issued a national emergency declaration to gain access to additional funds for his border wall despite receiving $1.375 billion from Congress.