Merge pull request #1546 from Bilb/master

Bump to v1.5.1
pull/1573/head v1.5.1
Audric Ackermann 4 years ago committed by GitHub
commit 35321c2bcb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -2,7 +2,7 @@
"name": "session-desktop",
"productName": "Session",
"description": "Private messaging from your desktop",
"version": "1.5.0",
"version": "1.5.1",
"license": "GPL-3.0",
"author": {
"name": "Loki Project",

@ -387,21 +387,25 @@ window.seedNodeList = JSON.parse(config.seedNodeList);
const { OnionPaths } = require('./ts/session/onions');
const { locale } = config;
window.i18n = i18n.setup(locale, localeMessages);
// moment does not support es-419 correctly (and cause white screen on app start)
const localeForMoment = locale === 'es-419' ? 'es' : locale;
const { locale: localFromEnv } = config;
window.i18n = i18n.setup(localFromEnv, localeMessages);
// moment does not support es-419 correctly (and cause white screen on app start)
window.moment = require('moment');
window.moment.updateLocale(localeForMoment, {
// Default to the locale from env. It will be overriden if moment
// does not recognize it with what moment knows which is the closest.
// i.e. es-419 will return 'es'.
// We just need to use what we got from moment on the updateLocale below
const localeSetForMoment = window.moment.locale(localFromEnv);
window.moment.updateLocale(localeSetForMoment, {
relativeTime: {
s: window.i18n('timestamp_s'),
m: window.i18n('timestamp_m'),
h: window.i18n('timestamp_h'),
},
});
window.moment.locale(localeForMoment);
window.OnionPaths = OnionPaths;

Loading…
Cancel
Save