[wp-trac] [WordPress Trac] #44107: wp_insert_user should return WP_Error if user_url's length is too long

WordPress Trac noreply at wordpress.org
Mon Jan 24 06:25:46 UTC 2022


#44107: wp_insert_user should return WP_Error if user_url's length is too long
-------------------------------------------------+-------------------------
 Reporter:  tszming                              |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  6.0
Component:  Users                                |     Version:  2.0
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests dev-        |     Focuses:
  feedback                                       |  administration
-------------------------------------------------+-------------------------
Changes (by sabernhardt):

 * component:  Administration => Users
 * milestone:  Awaiting Review => 6.0


Comment:

 Thanks for the patch!

 Please adjust the spacing so the equal signs line up and there are no
 extra spaces/tabs.

 {{{
         public function
 test_wp_insert_user_should_reject_user_url_over_100_characters() {
                 $user_url = str_repeat( 'a', 101 );
                 $u        = wp_insert_user(
                         array(
                                 'user_login' => 'test',
                                 'user_email' => 'test at example.com',
                                 'user_pass'  => 'password',
                                 'user_url'   => $user_url,
                         )
                 );

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/44107#comment:4>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list