From 12d33316918d6e333c670d0cc4a218bda2c964c6 Mon Sep 17 00:00:00 2001 From: Nicolas Legrand Date: Mon, 23 Sep 2019 18:27:32 +0200 Subject: [PATCH] Bug 23670: Load Koha::Exceptions::ElasticSearch module in Koha::SearchEngine::Elasticsearch MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Prevent Koha::SearchEngine::Elasticsearch from dying when trying to run Koha::Exceptions::Elasticsearch::MARCFieldExprParseError->throw() Plan test: 1. Go to Administration -> Searchengine configuration, and add a mapping for 995Z, whatever the search field (I did it with local-classification), save 2. run $KOHA_PATH/misc/search_tools/rebuild_elasticsearch.pl -v -d -b 3. see it die asking for Koha::Exceptions::Elasticsearch 4. apply patch 5. rerun $KOHA_PATH/misc/search_tools/rebuild_elasticsearch.pl -v -d -b 6. see it throw: Invalid MARC field expression: 995Z Signed-off-by: Séverine QUEUNE Signed-off-by: Nick Clemens Signed-off-by: Martin Renvoize --- Koha/SearchEngine/Elasticsearch.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/Koha/SearchEngine/Elasticsearch.pm b/Koha/SearchEngine/Elasticsearch.pm index ae0b7fdf48..ce1770320a 100644 --- a/Koha/SearchEngine/Elasticsearch.pm +++ b/Koha/SearchEngine/Elasticsearch.pm @@ -23,6 +23,7 @@ use C4::Context; use Koha::Database; use Koha::Exceptions::Config; +use Koha::Exceptions::Elasticsearch; use Koha::SearchFields; use Koha::SearchMarcMaps; -- 2.39.5