From: erickson Date: Fri, 17 Oct 2008 15:16:18 +0000 (+0000) Subject: after all search results scanned, we know the exact hit count, so use that instead... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=e4215ef458bb9d515b9ab5b814150a829b390472;p=Evergreen.git after all search results scanned, we know the exact hit count, so use that instead of the estimated count git-svn-id: svn://svn.open-ils.org/ILS/trunk@10860 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm b/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm index d2b838e191..ce1998809c 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Search/Biblio.pm @@ -877,7 +877,10 @@ sub staged_search { last if $current_count >= ($user_limit + $user_offset); # we've scanned all possible hits - last if $summary->{checked} < $superpage_size; + if($summary->{checked} < $superpage_size) { + $est_hit_count = scalar(@$all_results); + last; + } } my @results = grep {defined $_} @$all_results[$user_offset..($user_offset + $user_limit - 1)];