* elmo-filter.el (elmo-folder-search): Don't call elmo-list-filter
authorteranisi <teranisi>
Mon, 6 Oct 2003 01:38:09 +0000 (01:38 +0000)
committerteranisi <teranisi>
Mon, 6 Oct 2003 01:38:09 +0000 (01:38 +0000)
if numbers is nil.

elmo/ChangeLog
elmo/elmo-filter.el

index 8060c94..4dfdecf 100644 (file)
@@ -1,3 +1,8 @@
+2003-10-06  Yuuichi Teranishi  <teranisi@gohome.org>
+
+       * elmo-filter.el (elmo-folder-search): Don't call elmo-list-filter
+       if numbers is nil.
+
 2003-10-06  Yoichi NAKAYAMA  <yoichi@geiin.org>
 
        * elmo-util.el (toplevel): Require emu for char-list-to-string.
index c0a0817..75461ca 100644 (file)
 (luna-define-method elmo-folder-search ((folder elmo-filter-folder)
                                        condition &optional numbers)
   ;; search from messages in this folder
-  (elmo-list-filter
-   numbers
-   (elmo-folder-search (elmo-filter-folder-target-internal folder)
-                      condition
-                      (elmo-folder-list-messages folder))))
+  (let ((result (elmo-folder-search
+                (elmo-filter-folder-target-internal folder)
+                condition
+                (elmo-folder-list-messages folder))))
+    (if numbers
+       (elmo-list-filter numbers result)
+      result)))
 
 (luna-define-method elmo-message-use-cache-p ((folder elmo-filter-folder)
                                              number)