mirror of
https://github.com/ether/etherpad-lite.git
synced 2025-01-19 14:13:34 +01:00
Fixes #1498: Two-part locale specs in lang cookie wouldn't be read correctly
This commit is contained in:
parent
93d58b93be
commit
9ca2275432
1 changed files with 2 additions and 2 deletions
|
@ -1,8 +1,8 @@
|
|||
(function(document) {
|
||||
// Set language for l10n
|
||||
var language = document.cookie.match(/language=((\w{2,3})(-w+)?)/);
|
||||
var language = document.cookie.match(/language=((\w{2,3})(-\w+)?)/);
|
||||
if(language) language = language[1];
|
||||
|
||||
|
||||
html10n.bind('indexed', function() {
|
||||
html10n.localize([language, navigator.language, navigator.userLanguage, 'en'])
|
||||
})
|
||||
|
|
Loading…
Reference in a new issue