From 1e5e1d14c18e8d6ca69813ca5544a08c61e637bc Mon Sep 17 00:00:00 2001 From: Julian Maurice Date: Mon, 25 Jun 2018 14:14:43 +0200 Subject: [PATCH] Bug 19502: Add POD for max_result_window Signed-off-by: Nick Clemens Signed-off-by: Alex Arnaud --- Koha/SearchEngine/Elasticsearch/Search.pm | 9 +++++++++ Koha/SearchEngine/Zebra/Search.pm | 8 ++++++++ 2 files changed, 17 insertions(+) diff --git a/Koha/SearchEngine/Elasticsearch/Search.pm b/Koha/SearchEngine/Elasticsearch/Search.pm index 6b2f2a9..a1598d7 100644 --- a/Koha/SearchEngine/Elasticsearch/Search.pm +++ b/Koha/SearchEngine/Elasticsearch/Search.pm @@ -399,6 +399,15 @@ sub json2marc { return $marc; } +=head2 max_result_window + +Returns the maximum number of results that can be fetched + +This directly requests Elasticsearch for the setting index.max_result_window (or +the default value for this setting in case it is not set) + +=cut + sub max_result_window { my ($self) = @_; diff --git a/Koha/SearchEngine/Zebra/Search.pm b/Koha/SearchEngine/Zebra/Search.pm index 45c050c..576b9f5 100644 --- a/Koha/SearchEngine/Zebra/Search.pm +++ b/Koha/SearchEngine/Zebra/Search.pm @@ -110,6 +110,14 @@ sub search_auth_compat { C4::AuthoritiesMarc::SearchAuthorities(@params); } +=head2 max_result_window + +Returns the maximum number of results that can be fetched + +Zebra does not have such a limit, so it always returns undef + +=cut + sub max_result_window { undef } 1; -- 2.7.4