Twitter CEO Jack Dorsey on Tuesday told lawmakers that it was a “mistake” to censor the acting commissioner of Customs and Border Protection (CBP) over a tweet about the wall at the southern border -- as the company faces accusations of political bias.

Dorsey was grilled by Sen. Mike Lee, R-Utah, at a Senate Judiciary Committee hearing, where Lee brought up the incident in October -- in which CBP Acting Commissioner Mark Morgan was locked out of his account for a tweet touting the 400 miles of wall built at the border.

CBP CHIEF SAYS TWITTER LOCKED HIS ACCOUNT FOR PRO-BORDER WALL MESSAGE

“Every mile helps us stop gang members, murderers, sexual predators and drugs from entering our country,” the tweet said, declaring that “walls work.”

While the suspension was reversed by Twitter after an appeal, Lee asked why Twitter had initially determined the tweet violated rules governing “hateful conduct.”

“Can you tell me in one sentence what exactly is ‘hateful’ about Commissioner Morgan’s tweet?” he asked.

Dorsey said Twitter had “evaluated his tweet again and we found we were wrong.” 

“There was a mistake and it was due to the fact we had heightened awareness around government accounts during this time. So there was a mistake -- we reverted it,” he said.

FACEBOOK, TWITTER TAKE HEAT OVER HUNTER BIDEN STORY DURING HEARING; DORSEY ADMITS 'THIS ACTION WAS WRONG'

Twitter has faced a barrage of criticism from Republicans for alleged censorship of conservatives. In particular, it has come under scrutiny for its censorship of a New York Post story that reported on allegations about Hunter Biden.

Dorsey addressed the controversy in his opening remarks, explaining as he had during a previous hearing that the Post story was blocked pursuant to a 2018 policy against spreading hacked materials.

CLICK HERE TO GET THE FOX NEWS APP

"We made a quick interpretation using no other evidence that the materials in the article were obtained through hacking, and according to our policy, we blocked them from being spread," Dorsey testified. "Upon further consideration, we admitted this action was wrong and corrected it within 24 hours."

Fox News’ Ronn Blitzer contributed to this report.