[wp-trac] [WordPress Trac] #43869: Do not initialize current user too early in `get_user_locale()`

WordPress Trac noreply at wordpress.org
Thu Apr 26 14:13:07 UTC 2018


#43869: Do not initialize current user too early in `get_user_locale()`
-------------------------------------------------+-------------------------
 Reporter:  flixos90                             |       Owner:  (none)
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  Awaiting
                                                 |  Review
Component:  Bootstrap/Load                       |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  has-patch has-unit-tests 2nd-        |     Focuses:
  opinion                                        |
-------------------------------------------------+-------------------------
Changes (by flixos90):

 * keywords:  needs-patch needs-unit-tests => has-patch has-unit-tests 2nd-
     opinion


Comment:

 [attachment:43869.diff] gets rid of the unnecessary usage of user objects
 in `get_user_locale()` and also no longer sets the current user if the
 function is called too early in the bootstrap process. A patch to verify
 that behavior is also provided.

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


More information about the wp-trac mailing list