At a campaign event in Dallas on Friday, presidential hopeful Pete Buttigieg was confronted by hecklers who shouted anti-gay messages.

Buttigieg, the openly gay mayor of South Bend, Indiana, was speaking at the Dallas County Democratic Party's Johnson Jordan Dinner, The Texas Tribune reported.

One of the hecklers yelled “repent,” while another shouted that “marriage is between a man and a woman.” Buttigieg married his husband Chasten last year.

(Related: Pete Buttigieg, husband Chasten cover TIME magazine.)

Buttigieg, a veteran, reportedly responded to one heckler by saying that he served in Afghanistan “to defend that man's freedom of speech.” He also joked that the room was “lively.”

Former Texas Representative Beto O'Rourke, who is also vying for the Democratic presidential nomination, came to Buttigieg's defense.

“Texans don't stand for this kind of homophobia and hatred,” O'Rourke tweeted. “Mayor Pete, we are grateful you came to Texas and hope to see you and Chasten back again soon.”