Fix: (regexp) Properly join multiple regexps

Fixes #39.  Thanks to Milan Zamazal (@mz-pdm).
This commit is contained in:
Adam Porter 2019-08-25 19:51:26 -05:00
parent 9c38e96e73
commit 0585c368bd

View file

@ -401,7 +401,7 @@ replace the clause with a preamble."
;; Return element, because the predicate still needs testing. ;; Return element, because the predicate still needs testing.
element) element)
(`(regexp . ,regexps) (`(regexp . ,regexps)
(setq org-ql-preamble (rx-to-string `(or ,@regexps) t)) (setq org-ql-preamble (s-join "\\|" regexps))
;; Return nil, because we don't need to test the predicate. ;; Return nil, because we don't need to test the predicate.
nil) nil)
(`(todo . ,(and todo-keywords (guard todo-keywords))) (`(todo . ,(and todo-keywords (guard todo-keywords)))