British financial journalist Martin Lewis is dropping a lawsuit against Facebook after reaching a settlement with the company. Last year, Lewis alleged that Facebook defamed him by serving numerous ads that used his face and name to market sketchy financial products like cryptocurrency get-rich-quick schemes. Today, he announced that he settled the lawsuit in exchange for two commitments from Facebook: a £3 million (around $3.9 million) donation to the Citizens Advice charity organization and a new tool for reporting scam ads backed by a dedicated team to handle complaints.

Citizens Advice is creating a scam prevention initiative that includes awareness campaigns, advice for victims, and new tools for spotting online scams. It’s supposed to launch in May 2019, and Facebook will donate £2.5 million in funding over the next two years, plus £500,000 in free Facebook ads over three years. The reporting tool will be a UK-only feature. It’s intended to let users “easily and quickly flag ads that they believe to be scams violating Facebook’s advertising rules or other policies,” and it’s set to launch in a few months.

Facebook is “grateful” for being prodded on anti-scam measures

In a statement posted by Lewis and confirmed to The Verge, Facebook regional director Steve Hatch said he was “grateful to Martin Lewis for bringing attention to this important issue and for his guidance over the last eight months.” Hatch called this move “part of a wider commitment to tackling scams and to ensuring people are given more transparency and control over the ads they see on Facebook.”

Lewis hosts a long-running television series and regularly offers financial advice on other programs, and he’s the founder of personal finance site Money Saving Expert, among other projects. In April 2018, he complained that Facebook was letting scammers trade on his influence by posting ads where Lewis appeared to endorse their services, including a variety of cryptocurrency get-rich-quick ads.

Money Saving Expert claims fake endorsements have appeared on other platforms’ ads networks, including Twitter, Yahoo, and Google. Lewis called for these platforms to tackle the problem as well, but he offered unqualified praise of Facebook’s response, calling it “far above anything I could’ve won had I succeeded in a court.” While he argued that a lawsuit shouldn’t have been necessary, he said that “Facebook quickly realized the scale of the problem, its impact on real people, and agreed to commit to making a difference both on its own platform and across the wider sector.”