[wp-trac] [WordPress Trac] #36860: Introduce filter for users_have_content within delete action of users.php

WordPress Trac noreply at wordpress.org
Thu Sep 27 08:03:41 UTC 2018


#36860: Introduce filter for users_have_content within delete action of users.php
-------------------------------------------------+-------------------------
 Reporter:  garrett-eclipse                      |       Owner:  garrett-
                                                 |  eclipse
     Type:  enhancement                          |      Status:  accepted
 Priority:  normal                               |   Milestone:  4.9.9
Component:  Users                                |     Version:  4.6
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-testing needs-unit-  |     Focuses:
  tests                                          |  administration
-------------------------------------------------+-------------------------

Comment (by birgire):

 Few more suggestions for [attachment:"36860.3.diff"]

 - Add ''Default false.'' for the inline documentation of the
 {{{$users_have_content}}} input parameter.
 - Add missing {{{@param}}} for the {{{$userids}}} input parameter.
 - Code styling of `$users_have_content` in the filter's description.
 - Add "" around {{{users have flags}}} in the filter's description, to
 make it more readable.

 So the suggestion is to change:

 {{{
 /**
  * Filter to setup $users_have_content, also known as the users have
 content flag, before WordPress default checks.
  *
  * @since ###
  *
  * @param boolean $users_have_content The flag for users have content.
  */

 }}}

 to


 {{{
 /**
  * Filter to setup `$users_have_content`, also known as the "users have
 content" flag, before WordPress default checks.
  *
  * @since ###
  *
  * @param boolean $users_have_content The flag for users have content.
 Default false.
  * @param int[]   $userids            Array of IDs for users being
 deleted.
  */

 }}}

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


More information about the wp-trac mailing list