Commit d274bade681fd53aaf1bd7c4f272ae9402d99408
1 parent
0022afc9
Exists in
master
and in
19 other branches
No fuzzy transposition option until ES 6.1
Showing
1 changed file
with
5 additions
and
1 deletions
Show diff stats
lib/searchkick/query.rb
... | ... | @@ -335,7 +335,7 @@ module Searchkick |
335 | 335 | |
336 | 336 | if field.start_with?("*.") |
337 | 337 | q2 = qs.map { |q| {multi_match: q.merge(fields: [field], type: match_type == :match_phrase ? "phrase" : "best_fields")} } |
338 | - if below60? | |
338 | + if below61? | |
339 | 339 | q2.each do |q| |
340 | 340 | q[:multi_match].delete(:fuzzy_transpositions) |
341 | 341 | end |
... | ... | @@ -989,5 +989,9 @@ module Searchkick |
989 | 989 | def below60? |
990 | 990 | Searchkick.server_below?("6.0.0-alpha1") |
991 | 991 | end |
992 | + | |
993 | + def below61? | |
994 | + Searchkick.server_below?("6.1.0-alpha1") | |
995 | + end | |
992 | 996 | end |
993 | 997 | end | ... | ... |