Ansari recently began performing again after mostly retreating from the public eye last year after being accused of sexual misconduct by a woman who said she felt pressured into having sex with him while on a date.

Kaling's Instagram post was met with a flood of comments, with many fans criticizing her for attending Ansari's performance and giving it such a public show of support.

"Damn, this is disappointing," one commenter said. "I could get if you decided to go and privately support your friend but to then publicly endorse/rehab him kinda sucks."

Instagram / Mindy Kaling

Kaling replied that she thinks "it would be more cowardly to be his friend and not come to his defense when people disparage him in public."

"Obviously I don’t love responding to Instagram comments late on a Friday night but I’m a feminist and standing up for women is very important to me," she said. "I’m not rehabbing him [because] I think he did a fine job doing it himself."

Instagram

Another commenter said she was unfollowing Kaling because, they wrote, "as a survivor, this is disheartening," and added, "I believed you to be a champion of women."

"I am sorry to hear that. I am a champion of women," Kaling responded. "I am also a champion of my friend and do not believe they are mutually exclusive."

Kaling also responded to someone who wrote, "You can't separate the art from the artist. You believe the woman or you don't."

"I definitely don't separate the art from the artist," she replied. "His experience has shaped his art and he talked about [it] eloquently."

Instagram

Another commenter, who said Kaling kept deleting her comments, said she could "go to the show to support him [but] you don’t have to use your extremely powerful platform to sing his praises from the rooftops."

"He ignored a woman’s right to consent multiple times It DOES NOT MATTER how respectfully or humbly he’s been COACHED to talk about It in the past YEAR or more that he’s had to focus on repairing his fragmented reputation," the commenter said. "It doesn’t matter. His actions were despicable and instead of being the face of listening to women and turning a new leaf he’s stayed hidden like the rest of them!"

Kaling replied, saying, "I think comparing Aziz to R. Kelly was offensive and degrading to the victims of R. Kelly, so yeah, I deleted it."

Last year, the website Babe.net published a controversial account from a woman named only as Grace who alleged the comedian didn't pick on "verbal and non-verbal cues" that she was uncomfortable having sex with him.

At the time of the allegation, Ansari said he was "surprised and concerned" but promised to keep supporting the #MeToo movement.

At a show in New York earlier this month, he acknowledged the scandal, saying it's a "terrifying thing to talk about" and he hopes he's "become a better person" since.

“If that has made not just me but other guys think about this, and just be more thoughtful and aware and willing to go that extra mile, and make sure someone else is comfortable in that moment, that’s a good thing," he said at the show, according to Vulture.