Article will continue after advertisement

Earlier this week, Republican presidential nominee Donald Trump visited with some police officers in San Antonio, Texas.

Several of the officers displayed the famous red hat Trump has worn throughout the campaign. The hat bears the presidential candidate’s campaign slogan, “Make America Great Again.”

According to Fox San Antonio, the officers will face disciplinary action for violating uniform code.

‘The officers wearing the campaign hats while in uniform violated SAPD policy and will be disciplined appropriately,’ San Antonio Police Chief William McManus told the station.

RELATED: A Trump supporter who wore his hat to a protest of police brutality ended up running for his safety

The police chief and the mayor both agreed that the officers displayed poor judgement.

“I expect them to know better than to give the appearance of endorsing a candidate while on duty and in uniform, regardless of the political campaign or the candidate,” Chief McManus said.

“I am deeply disappointed by some of our SAPD officers’ lack of judgement. While on duty, police must be above politics with an obligation to serve everyone equally,” San Antonio Mayor Ivy Taylor added.

A spokesman for the San Antonio Police Officers Association claims the cops weren’t trying to be political, but were simply caught up in the moment.

“Frankly, the officers were most likely caught up in the moment and did not consider the political nature of their actions,” the spokesman said.

Module Voice Image