diff --git a/UI/WebServerResources/js/Mailer/Message.service.js b/UI/WebServerResources/js/Mailer/Message.service.js index 687b880ab..22704afdd 100644 --- a/UI/WebServerResources/js/Mailer/Message.service.js +++ b/UI/WebServerResources/js/Mailer/Message.service.js @@ -827,9 +827,10 @@ */ Message.prototype.$omit = function(options) { var message = {}, - privateAttributes = options && options.privateAttributes; - angular.forEach(this.editable, function(value, key) { - if (_.includes(['to', 'cc', 'bcc'], key)) { + privateAttributes = options && options.privateAttributes, + source = privateAttributes ? this : this.editable; + angular.forEach(source, function(value, key) { + if (_.includes(['to', 'cc', 'bcc'], key) && !privateAttributes) { message[key] = _.map(value, function (addr) { return addr.toString(); });