Support » Fixing WordPress » Newly created users roles problem on WP3.6

  • Resolved Taehan Lee

    (@taehan)


    I noticed that ‘option_name’ of user role was changed in ‘wpmu_create_user’ function like below.(wp-includes/ms-functions.php)

    From
    WP 3.5.x => delete_user_option( $user_id, ‘capabilities’ );
    to
    WP 3.6 => delete_user_option( $user_id, $user->cap_key );

    ‘delete_user_option’ function make option_name from ‘capabilities’ to ‘wp_capabilities’.(‘wp_’ is my table prefix)
    however, on wp3.6, it makes incorrect option_name. ‘wp_wp_capabilities'(twice table prefix)
    So, user role is not deleted.

    I resolved by adding third parameter like below.
    delete_user_option( $user_id, ‘capabilities’, true );
    but I want to know the reason of change on wp3.6.
    bug?

  • The topic ‘Newly created users roles problem on WP3.6’ is closed to new replies.