(js) Catch some exceptions to avoid console errors

This commit is contained in:
Francis Lachapelle committed 2017-12-19 09:53:48 -05:00
1 parent 37074086cf
commit 60bbe26289
5 files changed
+17 -1

No files matched your search

@@ -55,6 +55,11 @@
window.CKEDITOR.addCss('.cke_editable { font-size: ' + data.SOGoMailComposeFontSize + 'px; }');
}
_.forEach(data.AuxiliaryMailAccounts, function (mailAccount) {
if (isNaN(parseInt(mailAccount.port)))
mailAccount.port = null;
});
// We convert our list of autoReplyEmailAddresses/forwardAddress into a string.
// We also convert our date objects into real date, otherwise we'll have strings
// or undefined values and the md-datepicker does NOT like this.
@@ -148,6 +148,8 @@
}).then(function() {
vm.preferences.defaults.AuxiliaryMailAccounts[index] = account;
form.$setDirty();
}, function() {
// Cancel
});
};