Page MenuHomePhabricator

ArticleFeedbackv5-SpamRegex interoperability
Open, Needs TriagePublicFeature

Description

Currently ArticleFeedbackv5 supports the core MediaWiki $wgSpamRegex configuration variable. Support for it is implemented in ArticleFeedbackv5Utils::validateSpamRegex.
It'd be lovely if AFTv5 also supported the SpamRegex extension if and when that is installed alongside AFTv5.

I think the easiest way to go about this would be to add a new hook to the aforementioned method in AFTv5 and hook into that in SpamRegex.
But we can go and integrate the support for SpamRegex tighter, like how the existing SpamBlacklist support in AFTv5 is, if we make SpamRegex's SpamRegexHooks::fetchRegexData public and probably move it to the SpamRegex class since IIRC as well as based on a quick glance at the code, that's the best, recommended way to get spamregexed phrases and it's what the hooked functions in the SpamRegexHooks class use.