From 336d2000f8b3edd788bbdd49c4c5bc11c895a94d Mon Sep 17 00:00:00 2001 From: Aleksander Machniak <alec@alec.pl> Date: Mon, 11 Mar 2013 05:26:58 -0400 Subject: [PATCH] Fix handling of empty $uids argument in change_flag() --- program/lib/Roundcube/rcube_imap_cache.php | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/program/lib/Roundcube/rcube_imap_cache.php b/program/lib/Roundcube/rcube_imap_cache.php index f33ac07..748474a 100644 --- a/program/lib/Roundcube/rcube_imap_cache.php +++ b/program/lib/Roundcube/rcube_imap_cache.php @@ -485,7 +485,7 @@ .", flags = flags ".($enabled ? "+ $idx" : "- $idx") ." WHERE user_id = ?" ." AND mailbox = ?" - .($uids !== null ? " AND uid IN (".$this->db->array2list($uids, 'integer').")" : "") + .(!empty($uids) ? " AND uid IN (".$this->db->array2list($uids, 'integer').")" : "") ." AND (flags & $idx) ".($enabled ? "= 0" : "= $idx"), $this->userid, $mailbox); } -- Gitblit v1.9.1