Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
03/27/2014 06:02:00 PM (5 years ago)
Author:
boonebgorges
Message:

Enable Spam admin tools on non-MS users.php Dashboard panel

This change brings non-MS installations of BuddyPress closer to the
functionality that is native to WP Multisite, with respect to the ability to
manage spam/ham users from the Users panel. It also addresses a shortcoming
whereby admins on non-MS sites would have no way at all to spam/unspam users
if the Settings component was disabled, since the front-end Spam tools are in
that optional component.

Fixes #5113

Props imath, r-a-y

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-admin.php

    r8140 r8174  
    162162        add_action( 'bp_network_tool_box', 'bp_core_admin_available_tools_intro' );
    163163
     164        // On non-multisite, catch
     165        add_action( 'load-users.php', 'bp_core_admin_user_manage_spammers' );
     166
    164167        /** Filters ***********************************************************/
    165168
     
    167170        add_filter( 'plugin_action_links',               array( $this, 'modify_plugin_action_links' ), 10, 2 );
    168171        add_filter( 'network_admin_plugin_action_links', array( $this, 'modify_plugin_action_links' ), 10, 2 );
     172
     173        // Add "Mark as Spam" row actions on users.php
     174        add_filter( 'ms_user_row_actions', 'bp_core_admin_user_row_actions', 10, 2 );
     175        add_filter( 'user_row_actions',    'bp_core_admin_user_row_actions', 10, 2 );
    169176    }
    170177
Note: See TracChangeset for help on using the changeset viewer.