[wp-trac] [WordPress Trac] #34086: Issue creating users since 4.3 where custom user role is used.

WordPress Trac noreply at wordpress.org
Tue Sep 29 22:51:20 UTC 2015


#34086: Issue creating users since 4.3 where custom user role is used.
--------------------------+-----------------------------
 Reporter:  vegaskev      |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  Users         |    Version:  4.3.1
 Severity:  normal        |   Keywords:
  Focuses:                |
--------------------------+-----------------------------
 I have a custom user role (see code below).  For whatever reason, since
 updating to WordPress 4.3.1, I cannot create a new user and assign them
 this user role, nor can I edit any profile that is assigned to this custom
 user role. (same goes for any of my custom user roles).

 I've tried default generated password, custom strong, custom medium, and
 even weak ones while checking the checkbox.  Though, if I change the role
 to subscriber (or another native wp user role), it will work as intended.


 {{{
 function add_member_one(){
     $roles_set = get_option('member_1_set');
     if(!$roles_set){
         add_role('member_01', 'Member Level 1', array(
             'read' => true,
             'edit_posts' => false,
             'delete_posts' => false,
             'upload_files' => false
         ));
         update_option('member_1_set',true);
     }
 }
 add_action('plugins_loaded','add_member_one');
 }}}

 Here is the error message (even on the natively generated wp password,
 without touching the password field at all...


 {{{
 ERROR: Please make the password a medium or strong one.
 }}}

 NOTE: If I create a user as a subscriber, then create a custom password
 and change the user role, everything seems to work fine.  The only time it
 doesn't work correctly is when I try to assign a custom user role on user
 creation on the '/user-new.php' screen.

 Also.... I hadn't created any users during the short 4.3 period, so this
 issue may have occurred during the 4.3 - 4.3.1 period, I'm not 100% sure.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/34086>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list