Skip to:
Content

BuddyPress.org

Changeset 11738


Ignore:
Timestamp:
11/03/2017 09:11:47 PM (2 years ago)
Author:
boonebgorges
Message:

Remove logged-in check from bp_activity_remove_all_user_data().

This function is called on the delete_user and wpmu_delete_user hooks.
During normal operation, these hooks only fire for users with the
delete_users cap. So the is_user_logged_in() check is not necessary.
It also interferes with the ability to delete users fully in an
automated fashion, as by script.

Introduced in [3753].

Fixes #7621.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-activity/bp-activity-functions.php

    r11583 r11738  
    12611261 */
    12621262function bp_activity_remove_all_user_data( $user_id = 0 ) {
    1263 
    1264     // Do not delete user data unless a logged in user says so.
    1265     if ( empty( $user_id ) || ! is_user_logged_in() ) {
     1263    if ( empty( $user_id ) ) {
    12661264        return false;
    12671265    }
Note: See TracChangeset for help on using the changeset viewer.