-
Notifications
You must be signed in to change notification settings - Fork 913
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support special-case showing of a locale list at / if no accept-lang …
…header is present This changeset ensures we retain the existing behaviour where a robot/spider going to / with no accept-language header gets a 200 OK response but with a locale-picker page, NOT the homepage. The fix here was to avoid running Django's LocaleMiddleware when (and only when) we detect the special case of a request for the root path and no Accept-Language header - which is basically a call for the root page with no way to determine the client's locale. (We don't use sessions in Bedrock so Django will never find a language code in a session anyway)
- Loading branch information
1 parent
5be740b
commit 72c281e
Showing
3 changed files
with
71 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters