From c2f4404fca15be37228545b1893f5fa335168337 Mon Sep 17 00:00:00 2001 From: Tim Culverhouse Date: Tue, 5 Jul 2022 14:48:40 -0500 Subject: threading: enable filtering of server-side threads This patch enables the filtering of a threaded view which uses server-built threads. Filtering is done server-side, in order to preserve the use of server-built threads. In adding this feature, the filtering of notmuch folders was brought up to feature parity with the other workers. The filters function the same (ie: they can be stacked). The notmuch filters, however, still use notmuch syntax for the filtering. Signed-off-by: Tim Culverhouse Acked-by: Robin Jarry --- worker/imap/search.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'worker/imap/search.go') diff --git a/worker/imap/search.go b/worker/imap/search.go index f866b1cc..46a25c7c 100644 --- a/worker/imap/search.go +++ b/worker/imap/search.go @@ -11,6 +11,9 @@ import ( func parseSearch(args []string) (*imap.SearchCriteria, error) { criteria := imap.NewSearchCriteria() + if len(args) == 0 { + return criteria, nil + } opts, optind, err := getopt.Getopts(args, "rubax:X:t:H:f:c:") if err != nil { -- cgit