From 2965a981b7ec22866fbdf2d567d87e2d068d3617 Mon Sep 17 00:00:00 2001
From: Thomas Bruederli <thomas@roundcube.net>
Date: Fri, 31 Jul 2015 16:04:08 -0400
Subject: [PATCH] Allow to search and import missing PGP pubkeys from keyservers using Publickey.js

---
 program/lib/Roundcube/rcube_result_index.php |   21 ++++-----------------
 1 files changed, 4 insertions(+), 17 deletions(-)

diff --git a/program/lib/Roundcube/rcube_result_index.php b/program/lib/Roundcube/rcube_result_index.php
index 5f592c5..ffc1ad7 100644
--- a/program/lib/Roundcube/rcube_result_index.php
+++ b/program/lib/Roundcube/rcube_result_index.php
@@ -26,6 +26,8 @@
  */
 class rcube_result_index
 {
+    public $incomplete = false;
+
     protected $raw_data;
     protected $mailbox;
     protected $meta = array();
@@ -231,27 +233,11 @@
 
 
     /**
-     * Filters data set. Removes elements listed in $ids list.
+     * Filters data set. Removes elements not listed in $ids list.
      *
      * @param array $ids List of IDs to remove.
      */
     public function filter($ids = array())
-    {
-        $data = $this->get();
-        $data = array_diff($data, $ids);
-
-        $this->meta          = array();
-        $this->meta['count'] = count($data);
-        $this->raw_data      = implode(self::SEPARATOR_ELEMENT, $data);
-    }
-
-
-    /**
-     * Filters data set. Removes elements not listed in $ids list.
-     *
-     * @param array $ids List of IDs to keep.
-     */
-    public function intersect($ids = array())
     {
         $data = $this->get();
         $data = array_intersect($data, $ids);
@@ -332,6 +318,7 @@
         if (empty($this->raw_data)) {
             return array();
         }
+
         return explode(self::SEPARATOR_ELEMENT, $this->raw_data);
     }
 

--
Gitblit v1.9.1