Skip to:
Content

bbPress.org

Changeset 7288


Ignore:
Timestamp:
02/26/2025 06:06:46 PM (4 months ago)
Author:
johnjamesjacoby
Message:

Users: bail early out of profile-update if also during user sign-up.

This change ensures that the bbp_profile_update_role() function does not unintentionally run during user registration.

Props mungah, h1-2999394.

In branches/2.6, for 2.6.12.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.6/src/includes/users/capabilities.php

    r7087 r7288  
    273273 */
    274274function bbp_profile_update_role( $user_id = 0 ) {
     275
     276    // Bail if doing user registration actions
     277    if ( doing_action( 'bbp_user_register' ) || doing_action( 'register_new_user' ) ) {
     278        return;
     279    }
    275280
    276281    // Bail if no user ID was passed
Note: See TracChangeset for help on using the changeset viewer.