[wp-trac] [WordPress Trac] #36927: Disjointed WP_Error documentation and handling in wp-signup.php

WordPress Trac noreply at wordpress.org
Tue May 24 04:14:05 UTC 2016


#36927: Disjointed WP_Error documentation and handling in wp-signup.php
------------------------------------+-----------------------
 Reporter:  jeremyfelt              |      Owner:
     Type:  defect (bug)            |     Status:  new
 Priority:  normal                  |  Milestone:  4.6
Component:  Login and Registration  |    Version:
 Severity:  normal                  |   Keywords:  has-patch
  Focuses:  multisite               |
------------------------------------+-----------------------
 Most of the documentation for errors throughout `wp-signup.php` has the
 `$errors` data typed as `array` rather than `WP_Error`.

 In `show_user_form()` and `show_blog_form()`, an empty string is set as
 default for the `$errors` param, but it is used as a `WP_Error` object
 throughout.

 The likelihood of a fatal `Call to a member function get_error_message()
 on string` here is low, because this code is really self contained and
 somebody would need to filter responses to remove existing `WP_Error`
 objects completely. That said, we can still clean it up.

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


More information about the wp-trac mailing list