about summary refs log tree commit homepage
path: root/lib/PublicInbox/Search.pm
diff options
context:
space:
mode:
Diffstat (limited to 'lib/PublicInbox/Search.pm')
-rw-r--r--lib/PublicInbox/Search.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/PublicInbox/Search.pm b/lib/PublicInbox/Search.pm
index 76a270bc..b3fd532d 100644
--- a/lib/PublicInbox/Search.pm
+++ b/lib/PublicInbox/Search.pm
@@ -330,8 +330,10 @@ sub query_argv_to_string {
                 if (s!\b(d|rt|dt):([[:print:]]+)\z!date_parse_prepare(
                                                 $to_parse //= [], $1, $2)!sge) {
                         $_;
+                } elsif (/\s/) {
+                        s/(.*?)\b(\w+:)// ? qq{$1$2"$_"} : qq{"$_"};
                 } else {
-                        /\s/ ? (s/\A(\w+:)// ? qq{$1"$_"} : qq{"$_}) : $_
+                        $_
                 }
         } @$argv);
         # git-rev-parse can handle any number of args up to system