Fix sending message with "Too many public recipients" dialog buttons (#5924)

pull/6072/head
Aleksander Machniak 7 years ago
parent ec948564da
commit d0b99bd21d

@ -23,6 +23,7 @@ RELEASE 1.3.1
- Fix duplicate messages on the list after deleting messages on the next to the last page (#5862)
- Fix bug where messages count was not updated after delete when imap_cache is set (#5872)
- Fix potential XSS vulnerability with malformed HTML message markup
- Fix sending message with "Too many public recipients" dialog buttons (#5924)
- Bring back double-click behavior on the message list which was removed in 1.3.0 (#5823)
- Enigma: Fix decrypting an encrypted+signed message when signature verification fails (#5914)

@ -4423,7 +4423,7 @@ function rcube_webmail()
};
// checks the input fields before sending a message
this.check_compose_input = function(cmd, skip_recipients_checks)
this.check_compose_input = function(cmd)
{
// check input fields
var key, recipients, dialog,
@ -4449,8 +4449,7 @@ function rcube_webmail()
}
// check for empty recipient
recipients = get_recipients([input_to, input_cc, input_bcc]);
if (!skip_recipients_checks && !rcube_check_email(recipients, true)) {
if (!rcube_check_email(get_recipients([input_to, input_cc, input_bcc]), true)) {
alert(this.get_label('norecipientwarning'));
input_to.focus();
return false;
@ -4465,7 +4464,7 @@ function rcube_webmail()
}
// check disclosed recipients limit
if (limit && !skip_recipients_checks && !this.env.disclosed_recipients_warned
if (limit && !this.env.disclosed_recipients_warned
&& rcube_check_email(recipients = get_recipients([input_to, input_cc]), true, true) > limit
) {
var save_func = function(move_to_bcc) {
@ -4477,7 +4476,8 @@ function rcube_webmail()
}
dialog.dialog('close');
ref.check_compose_input(cmd, true);
if (ref.check_compose_input(cmd))
ref.command(cmd, { nocheck:true }); // repeat command which triggered this
};
dialog = this.show_popup_dialog(
@ -4510,7 +4510,8 @@ function rcube_webmail()
save_func = function() {
input_subject.val(prompt_value.val());
dialog.dialog('close');
ref.command(cmd, { nocheck:true }); // repeat command which triggered this
if (ref.check_compose_input(cmd))
ref.command(cmd, { nocheck:true }); // repeat command which triggered this
};
dialog = this.show_popup_dialog(

Loading…
Cancel
Save