Bug 23322: Correct case for boolean in ES search

I did not include tests only because this is a very small reasonable change and routine has no tests.
It does not affect behaviour, it only touches syntax lightly.

To test:
  0 - Set SearchEngine to ElasticSearch
  1 - Import the example record (a version is included in sample data in devbox/testing docker so you can skip)
  2 - Stage the attached example record
  3 - Match using 'ISBN' rule
  4 - No matches found
  5 - Apply patch
  6 - Restart all the things
  7 - Reapply matching with no rule
  8 - Reapply with ISBN matcing
  9 - It matches!
 10 - Set SearchEngine to Zebra
 11 - Reapply matching with no rule
 12 - Reapply with ISBN matching
 13 - Matching works as before in Zebra

Signed-off-by: Ron Houk <rhouk@ottumwapubliclibrary.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
This commit is contained in:
Nick Clemens 2019-07-16 12:08:47 +00:00 committed by Martin Renvoize
parent d71b263a89
commit ce1b79d55d
No known key found for this signature in database
GPG Key ID: 422B469130441A0F
1 changed files with 1 additions and 1 deletions

View File

@ -658,7 +658,7 @@ sub get_matches {
}
else {
my $phr = ( C4::Context->preference('AggressiveMatchOnISBN') || C4::Context->preference('AggressiveMatchOnISSN') ) ? ',phr' : q{};
$query = join( " or ",
$query = join( " OR ",
map { "$matchpoint->{'index'}$phr=\"$_\"" } @source_keys );
#NOTE: double-quote the values so you don't get a "Embedded truncation not supported" error when a term has a ? in it.
}