mirror of
https://github.com/nextcloud/server.git
synced 2026-05-28 04:32:30 -04:00
Merge pull request #21760 from nextcloud/fix/20453/get-plural
Fix parsing of language code
This commit is contained in:
commit
e18e4511d0
3 changed files with 4 additions and 4 deletions
2
core/js/dist/login.js
vendored
2
core/js/dist/login.js
vendored
File diff suppressed because one or more lines are too long
2
core/js/dist/main.js
vendored
2
core/js/dist/main.js
vendored
File diff suppressed because one or more lines are too long
|
|
@ -168,7 +168,7 @@ const L10n = {
|
|||
*/
|
||||
_getPlural: function(number) {
|
||||
let language = OC.getLanguage()
|
||||
if (language === 'pt_BR') {
|
||||
if (language === 'pt-BR') {
|
||||
// temporary set a locale for brazilian
|
||||
language = 'xbr'
|
||||
}
|
||||
|
|
@ -178,7 +178,7 @@ const L10n = {
|
|||
}
|
||||
|
||||
if (language.length > 3) {
|
||||
language = language.substring(0, language.lastIndexOf('_'))
|
||||
language = language.substring(0, language.lastIndexOf('-'))
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue