The photographs, hugs and congratulations from family members would have to wait.

First, several dozen of the nation’s newest citizens who gathered at the Institute of Texan Cultures in San Antonio would have to endure some harsh words about the state of the country they had just become a part of. The topic: President-elect Donald Trump.

Federal Magistrate Judge John Primomo presided over the induction ceremony late last week. In his speech to the émigrés, he touched on the protests that have cropped up across the nation since Trump’s election.

And he told those gathered what they could do if they didn’t like the person who won Nov. 8.

“I can assure you that whether you voted for [Trump] or you did not vote for him, if you are a citizen of the United States, he is your president and he will be your president,” the judge said, according to CBS affiliate KHOU. “And if you do not like that, you need to go to another country.”

Following several days of controversy over Primomo’s remarks — and calls for his punishment and possible termination — the judge on Monday was suspended from performing any other naturalization ceremonies, according to the San Antonio Express-News.

The following day, Primomo submitted notice for his retirement effective September, following his 65th birthday. Until then, he will continue to serve in his current capacity as a federal magistrate, “making bond decisions and holding other pre-trial hearings,” according to the Express-News.

Primomo, who did not return messages from The Washington Post, had also criticized American protesters who carried “he’s not my president” signs, according to KHOU.

The judge also lashed out against Colin Kaepernick and other National Football League players who choose to take a knee instead of standing during the national anthem.

“I detest that, because you can protest things that happen in this country; you have every right to,” Primomo said. “You don’t do that by offending national symbols like the national anthem and the flag of the United States.”

Primomo told San Antonio CBS affiliate KENS last week that he wanted his words to be unifying and respectful of the office of the president, not political or divisive.

He said that he didn’t vote for Trump.

Still, his words set off a controversy, with some calling for him to be removed from office.

Critics started a petition on MoveOn.org to censure the judge, who was appointed in 1988.

According to the Express-News, Primono’s letter of resignation, sent to U.S. district judges, “did not reference the controversy” over his remarks.

The newspaper noted:

Primomo declined to comment Tuesday, except to say he was not a Democrat nor Republican, but was “just trying to say something nice and it didn’t turn out that way.”

Since Trump won, thousands of people have protested in dozens of U.S. cities.

Among them were eight people who were arrested Saturday near Austin as White Lives Matter protesters clashed with counterprotesters, according to the Associated Press. The conflict happened after Texas Gov. Greg Abbott (R) dedicated a monument honoring African Americans’ contributions to the state.

Protesters interviewed by The Post have cited myriad reasons for taking to the streets — fears about climate change, even concerns about the electoral system and capitalism itself.

But mostly, they don’t like Trump.

Nationwide protests gripped many cities for days following the presidential election as thousands march against Donald Trump's victory. Trump tweeted to condemn "professional protesters, incited by the media." (Jenny Starrs/The Washington Post)

The protesters have faced their own criticism from people who said they should be working to unite the country, not divide it.

According to The Post’s Abigail Hauslohner and Mark Berman, “The protesters have earned the ire of Trump and his surrogates, who have insulted them on television and social media, calling them paid professionals ‘incited by the media,’ jobless ‘crybabies,’ people with mental disorders and ‘goons.’ ”

This story, which was originally published Nov. 21, has been updated.

Read more:

‘I’m planning to populate hell’: Judge is disciplined for ‘undignified’ comments in court

Take a ship ‘back to Africa’: Florida judge reassigned after alleged comments about black people

This attorney wore a Black Lives Matter pin to court — and went to jail for it