Closed Bug 746564 Opened 12 years ago Closed 11 years ago

Replace 'request.locale' with 'request.LANGUAGE_CODE'

Categories

(support.mozilla.org :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
2013Q1

People

(Reporter: jsocol, Assigned: fxa90id)

Details

(Whiteboard: u=dev c=general p=0 s=2013.3 [qa-])

The Django docs[1] indicate that the built-in translation middleware (which we don't use) prefers 'request.LANGUAGE_CODE'. For compatibility with 3rd party apps (and to make a waffle upgrade possible) we should switch.

This if probably a big patch, but almost entirely search-and-replace, unless some lines need to be rewrapped.

[1] https://docs.djangoproject.com/en/1.3/topics/i18n/deployment/#how-django-discovers-translations
Whiteboard: u=dev c=general s= p= [qa-]
To clarify, is this something we should fix sooner rather than later, or is this something we can stick in the code quality pile to be fixed in an upcoming house-keeping week?
Hello i would like to try this.

Thanks
Let me know if you have any questions!
Assignee: nobody → apokalyptica79
Whiteboard: u=dev c=general s= p= [qa-] → u=dev c=general p= [qa-]
Can I pick it?
(In reply to Michał Frontczak :fxa90id from comment #4)
> Can I pick it?

go for it :)
Assignee: apokalyptica79 → nobody
Assignee: nobody → michaljev
Landed on master:
https://github.com/mozilla/kitsune/commit/d3db15ec11cbb0ff26a2a179d83713c25229b97a
Whiteboard: u=dev c=general p= [qa-] → u=dev c=general p=0 s=2013.3 [qa-]
Target Milestone: --- → 2013Q1
Deployed to prod.
Status: NEW → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Thanks Michał this was awesome!
You need to log in before you can comment on or make changes to this bug.