[wp-trac] [WordPress Trac] #31166: wpmu_signup_user_notification filter is incorrect

WordPress Trac noreply at wordpress.org
Wed Jan 28 20:30:04 UTC 2015


#31166: wpmu_signup_user_notification filter is incorrect
------------------------------------+-----------------------------
 Reporter:  johnrom                 |      Owner:
     Type:  defect (bug)            |     Status:  new
 Priority:  normal                  |  Milestone:  Awaiting Review
Component:  Login and Registration  |    Version:  4.1
 Severity:  normal                  |   Keywords:
  Focuses:                          |
------------------------------------+-----------------------------
 Simple ticket here,

 The wpmu_signup_user_notification filter seems to be filtering the wrong
 option


 {{{

         if ( ! apply_filters( 'wpmu_signup_user_notification', $user,
 $user_email, $key, $meta ) )
                 return false;
 }}}

 If I'm thinking correctly, the filter should be filtering a boolean. If
 two filters are added to this and the first returns false, there is no way
 for the second filter to recover the $user variable.

 This is how I see it working

 WP4.1, /wp-includes/ms-functions.php line 919

 {{{

         if ( ! apply_filters( 'wpmu_signup_user_notification', true,
 $user, $user_email, $key, $meta ) )
                 return false;
 }}}

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


More information about the wp-trac mailing list