[wp-trac] [WordPress Trac] #19146: Remove $user_identity global usage in admin-bar.php

WordPress Trac wp-trac at lists.automattic.com
Fri Nov 4 09:51:09 UTC 2011


#19146: Remove $user_identity global usage in admin-bar.php
--------------------------+-----------------------------
 Reporter:  duck_         |      Owner:
     Type:  defect (bug)  |     Status:  new
 Priority:  normal        |  Milestone:  Awaiting Review
Component:  General       |    Version:  3.1
 Severity:  normal        |   Keywords:  has-patch
--------------------------+-----------------------------
 Used by the "My Account" menu, see [16077], the `$user_identity` global is
 back compat / 'deprecated' and we shouldn't use it, especially when we now
 have the full `$current_user` object via wp_get_current_user() anyway.

 See [3566] for "Setup global user vars.  Used by set_current_user() for
 back compat."

 Patch also makes use the local `$user_id` variable instead of re-calling
 get_current_user_id() again.

-- 
Ticket URL: <http://core.trac.wordpress.org/ticket/19146>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software


More information about the wp-trac mailing list