diff options
Diffstat (limited to 'program/js')
-rw-r--r-- | program/js/app.js | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/program/js/app.js b/program/js/app.js index e6cc28110..44afd5c7c 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -3607,16 +3607,18 @@ function rcube_webmail() { var rc; - if (!this.env.draft_id && id && (rc = this.opener())) { - // refresh the drafts folder in opener window - if (rc.env.task == 'mail' && rc.env.action == '' && rc.env.mailbox == this.env.drafts_mailbox) - rc.command('checkmail'); - } + if (id && id != this.env.draft_id) { + if (rc = this.opener()) { + // refresh the drafts folder in opener window + if (rc.env.task == 'mail' && rc.env.action == '' && rc.env.mailbox == this.env.drafts_mailbox) + rc.command('checkmail'); + } - this.env.draft_id = id; - $("input[name='_draft_saveid']").val(id); + this.env.draft_id = id; + $("input[name='_draft_saveid']").val(id); - this.remove_compose_data(this.env.compose_id); + this.remove_compose_data(this.env.compose_id); + } }; this.auto_save_start = function() |