From 48c05f60ed34739f051647e64e8b4388f4c298ec Mon Sep 17 00:00:00 2001 From: Rok Garbas Date: Sun, 30 Aug 2020 14:48:04 +0200 Subject: [PATCH] using whitespace analyzer and not the default one (#172) fixes #171 --- src/Search.elm | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Search.elm b/src/Search.elm index cbe257c..aef72f1 100644 --- a/src/Search.elm +++ b/src/Search.elm @@ -751,6 +751,7 @@ search_fields query fields = [ ( "type", Json.Encode.string "most_fields" ) , ( "query", Json.Encode.string queryWord ) , ( "fuzziness", Json.Encode.int <| String.length queryWord // 5 ) + , ( "analyzer", Json.Encode.string "whitespace" ) , ( "operator", Json.Encode.string "or" ) , ( "_name" , Json.Encode.string <| "multi_match_" ++ queryWord ++ "_" ++ (queryIndex + 1 |> String.fromInt)