phrases: only allow for index fields

This commit is contained in:
djcb
2017-10-27 18:42:58 +03:00
parent fe18603843
commit 6ce7c89488
4 changed files with 16 additions and 6 deletions

View File

@ -52,6 +52,9 @@ static Xapian::Query
xapian_query_value (const Mux::Tree& tree)
{
const auto v = dynamic_cast<Value*> (tree.node.data.get());
if (!v->phrase)
return Xapian::Query(v->prefix + v->value);
const auto parts = split (v->value, " ");
std::vector<Xapian::Query> phvec;