Merge pull request #1080 from Pistil-Studio/patch-1
Update tarteaucitron.js
This commit is contained in:
commit
125f00c77c
|
|
@ -1821,8 +1821,8 @@ var tarteaucitron = {
|
||||||
}
|
}
|
||||||
|
|
||||||
// get the html lang
|
// get the html lang
|
||||||
if (availableLanguages.indexOf(document.documentElement.getAttribute("lang")) !== -1) {
|
if (availableLanguages.indexOf(document.documentElement.getAttribute("lang").substr(0, 2)) !== -1) {
|
||||||
return document.documentElement.getAttribute("lang");
|
return document.documentElement.getAttribute("lang").substr(0, 2);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!navigator) { return defaultLanguage; }
|
if (!navigator) { return defaultLanguage; }
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue