William C. Bradford, who tweeted racist and anti-Semitic comments before being appointed by President Donald Trump to lead the Department of Energy’s Office of Indian Energy, resigned from his position on Thursday.

Energy Department spokeswoman Shaylyn Hynes confirmed his departure in an email to HuffPost on Friday, stating that Bradford “tendered his resignation yesterday.”

“[He] is no longer with the Department of Energy,” Hynes said.

Earlier this week, CNN reported that Bradford appeared to own an online account that described former President Barack Obama as “the son of a fourth-rate p&*n actress and w@!re” on the internet commenting platform Disqus in 2016.

Bradford denied being linked to the account and told CNN that he was the victim of “cyber attacks and Internet crimes,” despite posts by the account encouraging other users to contact the user at Bradford’s email address and phone number.

Bradford told HuffPost in an email Friday that he resigned because he felt “the best way to serve the President, the USA, and Indian Country would be from a position beyond the constraints” he said he experienced during his brief tenure at the Energy Department.

“I look forward to helping make America great again in another role,” Bradford wrote.

The CNN report is only the latest social media scandal to haunt Bradford. In June, the then-senior Energy Department official came under fire after The Washington Post published a trove of deleted tweets written in 2016.

Twitter/Washington Post

In one tweet, Bradford described Obama as a “Kenyan creampuff.” In February 2016, Bradford went on anti-Semitic Twitter rant against Facebook co-founder Mark Zuckerberg, calling him an “arrogant self-hating Jew.”

A few weeks later, Bradford said it was “necessary” to incarcerate nearly 120,000 people of Japanese descent in the U.S. during World War II.

Twitter/Washington Post

Bradford quickly acknowledged the deleted tweets and apologized for his “disrespectful and offensive” comments.

“As a minority and member of the Jewish faith, I sincerely apologize,” wrote Bradford, who is also a member of the Chiricahua Apache Nation, in an email to The Washington Post.

Bradford also made headlines in 2015 when he resigned from his position as a West Point law professor amid backlash over an article he published that urged attacks on Islamic holy sites. A month earlier, The Guardian reported that he had inflated his military and academic credentials.