Explorar o código

Fix failing tests

JC Brand %!s(int64=8) %!d(string=hai) anos
pai
achega
6045b3d1e1
Modificáronse 2 ficheiros con 2 adicións e 1 borrados
  1. 1 1
      src/converse-notification.js
  2. 1 0
      src/locales.js

+ 1 - 1
src/converse-notification.js

@@ -163,7 +163,7 @@
                 }
                 var n = new Notification(title, {
                         body: message.querySelector('body').textContent,
-                        lang: _converse.i18n.locale_data.converse[""].lang,
+                        lang: _.isEmpty(converse.i18n) ? 'en' : _converse.i18n.locale_data.converse[""].lang,
                         icon: _converse.notification_icon
                     });
                 setTimeout(n.close.bind(n), 5000);

+ 1 - 0
src/locales.js

@@ -28,6 +28,7 @@
         'text!zh'
         ], function ($, Jed) {
             root.locales = {
+                'en':     {},
                 'af':     arguments[1],
                 'ca':     arguments[2],
                 'de':     arguments[3],