Skip to content

Commit

Permalink
Check for empty search string (#3074)
Browse files Browse the repository at this point in the history
So it does not get propagated as filter

Co-authored-by: Colin de Roos <colin@driebit.nl>
  • Loading branch information
cdfa and Colin de Roos committed Jul 28, 2022
1 parent 97b98e8 commit 3883021
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions modules/mod_search/support/search_query.erl
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,8 @@ parse_query([{text, Text}|Rest], Context, Result) ->
mod_search:find_by_id(S, Context);
[] ->
parse_query(Rest, Context, Result);
<<>> ->
parse_query(Rest, Context, Result);
_ ->
TsQuery = mod_search:to_tsquery(Text, Context),
{QArg, Result1} = add_arg(TsQuery, Result),
Expand Down

0 comments on commit 3883021

Please sign in to comment.