California Attorney General Xavier Becerra on Tuesday warned that he is prepared to challenge President Trump in court should he declare a national emergency to fund the border wall.

Becerra’s remarks came during a nationally televised address as part of the Democrats’ Spanish-language response to Trump’s State of the Union address. He condemned Trump’s characterization of immigration, the partial government shutdown over the wall and the president’s threat to cut federal funding to the state’s communities devastated by wildfires, the Los Angeles Times reported.

TRUMP URGES BORDER WALL IN STATE OF THE UNION, SAYS TOLERANCE FOR ILLEGAL IMMIGRATION IS 'CRUEL'

“What we heard tonight was the same tired refrain of building walls,” Becerra said. “The idea of declaring a nonexistent state of emergency on the border, in order to justify robbing funds that belong to the victims of fires, floods, hurricanes, and droughts, to pay for the wall is not only immoral. It is illegal.

“We are ready to reject this foolish proposal in court the moment it touches the ground,” Becerra said.

CALIFORNIA EFFORTS VS. TRUMP COSTING STATE TAXPAYERS MILLIONS: REPORT

Becerra, 61, has so far has challenged the Trump administration in court 45 times as attorney general over federal actions on issues including immigration, healthcare, the environment, the U.S. census, education and the internet, the paper reported.

CLICK HERE TO GET THE FOX NEWS APP