Re: Akismet flagging lots of valid replies/topics as spam HERE
Here’s a mini-plugin that will allow higher roles to skip akismet, if you turn the throttle bypass on for any member, they will also bypass akismet with this:
<?php
/*
Plugin Name: Skip Akismet
Description: Allow moderators, admin and specified roles to bypass Akismet filter
Author: _ck_
*/
// add any other custom roles to this list
$skip_akismet=array('moderator','administrator','keymaster');
add_action('bb_init','skip_akismet');
function skip_akismet() {
global $bb_current_user,$bbdb;
if (empty($bb_current_user->ID)) {return;}
$capabilities=$bbdb->prefix."capabilities";
$role=reset(array_keys($bb_current_user->data->$capabilities));
if (in_array($role,$skip_akismet) || bb_current_user_can('throttle') || bb_current_user_can('moderate')) {
remove_action( 'pre_post', 'bb_ksd_check_post', 1 );
remove_filter( 'bb_new_post', 'bb_ksd_new_post' );
remove_filter( 'pre_post_status', 'bb_ksd_pre_post_status' );
}
}
?>