mirror of
https://github.com/bitwarden/browser
synced 2024-12-27 02:14:24 +01:00
sanitize system language
This commit is contained in:
parent
2930d7daf7
commit
94ca579168
@ -12,7 +12,9 @@ export class I18nService implements I18nServiceAbstraction {
|
||||
protected localeMessages: any = {};
|
||||
|
||||
constructor(protected systemLanguage: string, protected localesDirectory: string,
|
||||
protected getLocalesJson: (formattedLocale: string) => Promise<any>) { }
|
||||
protected getLocalesJson: (formattedLocale: string) => Promise<any>) {
|
||||
this.systemLanguage = systemLanguage.replace('_', '-');
|
||||
}
|
||||
|
||||
async init(locale?: string) {
|
||||
if (this.inited) {
|
||||
|
Loading…
Reference in New Issue
Block a user