mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-24 06:03:49 +00:00
Merge "Add option to have private filters notify UDP/RC (default: disabled)"
This commit is contained in:
commit
c99f99a755
|
@ -898,7 +898,7 @@ class AbuseFilter {
|
|||
$wgMemc->incr( self::filterMatchesKey() );
|
||||
|
||||
$local_log_ids = array();
|
||||
global $wgAbuseFilterNotifications;
|
||||
global $wgAbuseFilterNotifications, $wgAbuseFilterNotificationsPrivate;
|
||||
foreach ( $log_rows as $index => $data ) {
|
||||
$data['afl_var_dump'] = $var_dump;
|
||||
$data['afl_id'] = $dbw->nextSequenceValue( 'abuse_filter_log_afl_id_seq' );
|
||||
|
@ -924,7 +924,7 @@ class AbuseFilter {
|
|||
'actions' => $data['afl_actions'],
|
||||
'log' => $data['afl_id'],
|
||||
) );
|
||||
if ( self::filterHidden( $data['afl_filter'] ) ) {
|
||||
if ( self::filterHidden( $data['afl_filter'] ) && !$wgAbuseFilterNotificationsPrivate ) {
|
||||
continue;
|
||||
}
|
||||
$entry->publish( 0, $wgAbuseFilterNotifications );
|
||||
|
|
|
@ -167,6 +167,8 @@ $wgAbuseFilterRestrictedActions = array( 'block', 'degroup' );
|
|||
|
||||
// Abuse filter hit notification (available options: rc, udp, rcandudp)
|
||||
$wgAbuseFilterNotifications = false;
|
||||
// Enable notifications for private filters
|
||||
$wgAbuseFilterNotificationsPrivate = false;
|
||||
|
||||
// Centralised filters
|
||||
$wgAbuseFilterCentralDB = null;
|
||||
|
|
Loading…
Reference in a new issue