Aleksander Machniak
2013-06-02 6213c6a6e18848d861f2add83bdb69a1de3f5956
Fix removing flags from serialized object before saving it in DB
1 files modified
4 ■■■ changed files
program/lib/Roundcube/rcube_imap_cache.php 4 ●●● patch | view | raw | blame | history
program/lib/Roundcube/rcube_imap_cache.php
@@ -407,8 +407,8 @@
            return;
        }
        $msg   = serialize($this->db->encode(clone $message));
        $flags = 0;
        $msg   = clone $message;
        if (!empty($message->flags)) {
            foreach ($this->flags as $idx => $flag) {
@@ -417,7 +417,9 @@
                }
            }
        }
        unset($msg->flags);
        $msg = serialize($this->db->encode($msg));
        // update cache record (even if it exists, the update
        // here will work as select, assume row exist if affected_rows=0)