From bba25299f8d1569f560fc66f82837c95145ee121 Mon Sep 17 00:00:00 2001 From: alecpl Date: Thu, 22 Sep 2011 07:49:33 +0000 Subject: - Fix bug where after delete message rows can be added to the list of another folder (#1487752) --- program/js/app.js | 16 ++++++++++++++-- 1 file changed, 14 insertions(+), 2 deletions(-) (limited to 'program/js/app.js') diff --git a/program/js/app.js b/program/js/app.js index 65d4f066f..a9fbe987d 100644 --- a/program/js/app.js +++ b/program/js/app.js @@ -1641,6 +1641,10 @@ function rcube_webmail() if (!this.gui_objects.messagelist || !this.message_list) return false; + // Prevent from adding messages from different folder (#1487752) + if (flags.mbox != this.env.mailbox && !flags.skip_mbox_check) + return false; + if (!this.env.messages[uid]) this.env.messages[uid] = {}; @@ -2091,8 +2095,12 @@ function rcube_webmail() }; // Initializes threads indicators/expanders after list update - this.init_threads = function(roots) + this.init_threads = function(roots, mbox) { + // #1487752 + if (mbox && mbox != this.env.mailbox) + return false; + for (var n=0, len=roots.length; n