[FIX] mail: replace _lt to _t for mailboxes' name

Since mailboxes are added after the rpc 'mail/init_message', the translations
are loaded. Therefore it is not necessary to lazily load the translations.
This commit is contained in:
Alexandre Kühn
2018-07-19 14:01:58 +02:00
parent 0f65c4ab3b
commit 04c98eeb48
2 changed files with 5 additions and 5 deletions
@@ -53,7 +53,7 @@ var AbstractThread = Class.extend({
/**
* Get the name of this thread
*
* @returns {string|Object} object for lazy translated names with _lt
* @returns {string}
*/
getName: function () {
return this._name;
@@ -69,7 +69,7 @@ var AbstractThread = Class.extend({
/**
* Returns the title to display in thread window's headers.
*
* @returns {string|Object} the name of the thread by default (see @getName)
* @returns {string} the name of the thread by default (see @getName)
*/
getTitle: function () {
return this.getName();
@@ -884,19 +884,19 @@ var MailManager = AbstractService.extend({
_initializeMailboxes: function (data) {
this._addMailbox({
id: 'inbox',
name: _lt("Inbox"),
name: _t("Inbox"),
mailboxCounter: data.needaction_inbox_counter || 0,
});
this._addMailbox({
id: 'starred',
name: _lt("Starred"),
name: _t("Starred"),
mailboxCounter: data.starred_counter || 0,
});
if (data.is_moderator) {
this._addMailbox({
id: 'moderation',
name: _lt("Moderate Messages"),
name: _t("Moderate Messages"),
mailboxCounter: data.moderation_counter || 0,
});
}