]> git.eshelyaron.com Git - emacs.git/commitdiff
Fix bum namazu search command
authorEric Abrahamsen <eric@ericabrahamsen.net>
Thu, 18 May 2017 13:47:03 +0000 (21:47 +0800)
committerEric Abrahamsen <eric@ericabrahamsen.net>
Fri, 26 May 2017 05:47:43 +0000 (13:47 +0800)
* lisp/gnus/gnus-search.el (gnus-search-indexed-search-command): Had
  named it incorrectly. Also switch to using nconc.

lisp/gnus/gnus-search.el

index 37fc197426edc28352d5fae4a64124a6afb2906b..886905e46256f575c8df993f535201f062f327cc 100644 (file)
@@ -1533,19 +1533,18 @@ fudges a relevancy score of 100."
     (setenv "LC_MESSAGES" "C")
     (cl-call-next-method)))
 
-(cl-defmethod search-indexed-search-command ((engine gnus-search-namazu)
-                                            (qstring string)
-                                            query &optional _groups)
+(cl-defmethod gnus-search-indexed-search-command ((engine gnus-search-namazu)
+                                                 (qstring string)
+                                                 query &optional _groups)
   (let ((max (alist-get 'limit query)))
     (with-slots (switches index-dir) engine
-      `("-q"                           ; don't be verbose
-       "-a"                            ; show all matches
-       "-s"                            ; use short format
-       ,(if max (format "--max=%d" max) "")
-       ,@switches
-       ,qstring                        ; the query, in namazu format
-       ,index-dir                      ; index directory
-       ))))
+      (nconc
+       (list "-q"                      ; don't be verbose
+            "-a"                       ; show all matches
+            "-s")                      ; use short format
+       (when max (list (format "--max=%d" max)))
+       switches
+       (list qstring index-dir)))))
 
 (cl-defmethod gnus-search-indexed-extract ((engine gnus-search-namazu))
   "Extract a single message result for Namazu.