[wp-trac] [WordPress Trac] #38632: Ability to change a user language back to site's language is missing

WordPress Trac noreply at wordpress.org
Tue Nov 8 14:26:19 UTC 2016


#38632: Ability to change a user language back to site's language is missing
-------------------------------------------------+-------------------------
 Reporter:  ocean90                              |       Owner:
     Type:  defect (bug)                         |      Status:  new
 Priority:  normal                               |   Milestone:  4.7
Component:  I18N                                 |     Version:  trunk
 Severity:  normal                               |  Resolution:
 Keywords:  2nd-opinion has-patch has-unit-      |     Focuses:
  tests                                          |  administration
-------------------------------------------------+-------------------------

Comment (by joehoyle):

 @ocean90 Hmm ok, my only concern with this is it's not easy to localize
 things for API clients when the majority of users are going to have the
 site's locale (that's by default anyway), which renders this field fairly
 useless in the case of the REST API. It seems like most of the time one
 would need to get the site's locale "global" setting rather than relying
 on this fields, as this field is going to be `''` most of the time.

 I'm tempted to suggest that the API's value for a user's locale should
 fall through to the site's default, so it's more usable for api consumers.
 Like settings, you could then send `locale => null` to the REST API reset
 it to it's default (site setting), under the hood this would just set it
 to an empty string of course.

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


More information about the wp-trac mailing list