I recently had to switch back to using Akismet for anti-spam because my previous solution, WP Zero Spam, was causing issues with Gravity Forms, such that forms were not being submitted and I wasn’t getting any contact messages. By default, Akismet wipes the comment spam queue every 15 days, which is too long for me (at the current rate, I’d have close to 1,000 by then). I did some peeking under the hood of Akismet and found exactly what I was looking for: a filter to change the frequency at which Akismet runs the spam deletion process.
This snippet changes the interval to daily, forcing Akismet to delete all spam messages every day rather than every 15 days.
Leave a Reply