aboutsummaryrefslogtreecommitdiffhomepage
path: root/shared/models
diff options
context:
space:
mode:
Diffstat (limited to 'shared/models')
-rw-r--r--shared/models/i18n/i18n.ts4
1 files changed, 4 insertions, 0 deletions
diff --git a/shared/models/i18n/i18n.ts b/shared/models/i18n/i18n.ts
index 2d3a1d3e2..4d50bc36e 100644
--- a/shared/models/i18n/i18n.ts
+++ b/shared/models/i18n/i18n.ts
@@ -7,6 +7,10 @@ export function getDefaultLocale () {
7 return 'en-US' 7 return 'en-US'
8} 8}
9 9
10export function isDefaultLocale (locale: string) {
11 return locale === getDefaultLocale()
12}
13
10const possiblePaths = Object.keys(I18N_LOCALES).map(l => '/' + l) 14const possiblePaths = Object.keys(I18N_LOCALES).map(l => '/' + l)
11export function is18nPath (path: string) { 15export function is18nPath (path: string) {
12 return possiblePaths.indexOf(path) !== -1 16 return possiblePaths.indexOf(path) !== -1