mirror of
https://github.com/the-djmaze/snappymail.git
synced 2026-08-31 13:09:21 +03:00
Code refactoring (promises for folders management)
This commit is contained in:
parent
9bec1d0a8f
commit
bab64a7cea
19 changed files with 467 additions and 333 deletions
|
|
@ -235,9 +235,10 @@
|
|||
/**
|
||||
* @param {number} iCode
|
||||
* @param {*=} mMessage = ''
|
||||
* @param {*=} mDefCode = null
|
||||
* @return {string}
|
||||
*/
|
||||
Translator.prototype.getNotification = function (iCode, mMessage)
|
||||
Translator.prototype.getNotification = function (iCode, mMessage, mDefCode)
|
||||
{
|
||||
iCode = window.parseInt(iCode, 10) || 0;
|
||||
if (Enums.Notification.ClientViewError === iCode && mMessage)
|
||||
|
|
@ -245,7 +246,9 @@
|
|||
return mMessage;
|
||||
}
|
||||
|
||||
return _.isUndefined(this.notificationI18N[iCode]) ? '' : this.notificationI18N[iCode];
|
||||
return _.isUndefined(this.notificationI18N[iCode]) ? (
|
||||
mDefCode && _.isUndefined(this.notificationI18N[mDefCode]) ? this.notificationI18N[mDefCode] : ''
|
||||
) : this.notificationI18N[iCode];
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue