The Flash has fired Elongated Man actor Hartley Sawyer following the discovery of misogynist and racist Tweets on his social media.

According to The Hollywood Reporter, Sawyer has since deleted his Twitter, which contained jokes involving sexual assault, racism and homophobia. In response to these Tweets, The CW and showrunner Eric Wallace have released a joint statement explaining why they fired him from the Arrowverse series.

RELATED: Flash Actor Shares Photos Of Rubber Bullet Injuries Sustained During Protests

"Hartley Sawyer will not be returning for season seven of The Flash," the statement reads. "In regards to Mr. Sawyer's posts on social media, we do not tolerate derogatory remarks that target any race, ethnicity, national origin, gender or sexual orientation. Such remarks are antithetical to our values and polices, which strive and evolve to promote a safe, inclusive and productive environment for our workforce."

The Tweets that led to Sawyer's firing, which resurfaced online recently, were written largely between 2011 and 2014 and contain sensitive topics. "If I had a wife I would beat the hell out of her tonight lol," he wrote in a 2012 Tweet. In another, he posted, "The only thing keeping me from doing mildly racist tweets is the knowledge that Al Sharpton would never stop complaining about me." "Personally I don't think I would ever 'let a thug hit it' but that's just me," he said in 2014.

RELATED: The CW Announces January Return Date For Fall Series

Sawyer has since issued an apology on his Instagram. "I'm not here to make excuses," he wrote. "Regardless of the intention, my words matter and they carry profound consequences. And mine can and have caused pain and embarrassment, along with feelings I can only imagine, to my supporters and fans, my cast mates, the crew, my colleagues and friends. I owe them all an apology. And I owe each of you an apology. Thank you for holding me accountable." The message continued into the caption, where he added, "I am incredibly sorry, ashamed and disappointed in myself for my ignorance back then. I want to be very clear: this is not reflective of what I think or who I am now."

Sawyer joined The Flash in Season 4 as Ralph Dibny, aka Elongated Man, and became a series regular on the show. Dibny's journey saw him transform from a misogynistic creep into a full-blown superhero. Following the introduction of Sue Dearbon, Dibny took on a central role in Season 6, which set up a romance between the two for Season 7. At the time of writing, it is unclear how The CW intends to move forward with the character; given his shape-changing powers, the role could be recast, or the show may move forward without him.

Returning to The CW for its seventh season, The Flash stars Grant Gustin, Candice Patton, Carlos Valdes, Danielle Panabaker, Tom Cavanagh, Jesse L. Martin and Danielle Nicolet.

KEEP READING: Flash Season 7 Synopsis Threatens Barry And Iris' Marriage