[wp-trac] [WordPress Trac] #46302: Coding consistency, found more $request_data that should be $request

WordPress Trac noreply at wordpress.org
Fri Jan 31 07:52:44 UTC 2020


#46302: Coding consistency, found more $request_data that should be $request
-------------------------------------------------+-------------------------
 Reporter:  garrett-eclipse                      |       Owner:  (none)
     Type:  enhancement                          |      Status:  new
 Priority:  normal                               |   Milestone:  5.4
Component:  Privacy                              |     Version:  4.9.6
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch needs-testing needs-dev-   |     Focuses:
  note                                           |  administration
-------------------------------------------------+-------------------------
Changes (by garrett-eclipse):

 * keywords:   => has-patch needs-testing needs-dev-note
 * focuses:  privacy => administration
 * component:  Administration => Privacy
 * version:   => 4.9.6
 * milestone:  Awaiting Review => 5.4


Comment:

 Coming back to review the instances of $request_data I'd initially flagged
 were valid as they represented the array form of request data. The
 `wp_get_user_request_data` function on the other hand specifically returns
 the WP_User_Request object which in itself has a $request_data property.
 To avoid confusion with this I've uploaded an initial patch to update the
 function to `wp_get_user_request` in order to clarify it's purpose. To
 maintain back-compat I've deprecated the function.

 Please review and test, so far beyond throwing the deprecation warning
 with use of the old function there's no change to the request
 functionality.

 Flagging for testing and dev-note.

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


More information about the wp-trac mailing list