A University of North Texas attorney resigned Friday less than 24 hours after she used a racial slur while giving examples of free speech at an event called “When Hate Comes to Campus.”

Assistant general counsel Caitlin Sewell was speaking in a panel discussion Thursday when she used the N-word word, FOX 4 of Dallas reported.

“You know, you can say a lot of offensive things in here because it’s impossible to talk about the First Amendment without saying horrible things," she said in front of an audience. "Um, you know, ‘You’re just a dumb n----- and I hate you.’ That alone, that’s protected speech.”

ACTOR APOLOGIZES FOR USING N-WORD DURING PANEL DISCUSSION

Several members of the audience became outraged, questioning Sewell about why she would choose to say the N-word but then later censor herself instead of using the F-word.

Sewell apologized immediately and said she didn’t mean to offend anyone.

“I understand what she’s trying to say, in that we have the right to say anything in this country, however, she explicitly decided to censor the F-word, and after that happened, it made me feel as though she just negated my entire identity,” UNT Student Government Association President Yolian Ogbu said, according to FOX 4.

Ogbu and Cameron Combs, president of UNT’s Black Student Union, called for Sewell’s resignation and by Friday morning she had resigned.

“We strongly believe in a culture that embraces, and vehemently defends inclusion. While Ms. Sewell was trying to make a point about First Amendment speech, the references used are never condoned in our community, which prides itself in our diversity and caring nature,” the president wrote in the statement.

CLICK HERE TO GET THE FOX NEWS APP

The president's statement said the school plans to engage in a dialogue with students and campus leaders about fostering a “culture of diversity," FOX 4 reported.