$mset->size is probably more obvious than relying on a tied
array and saves us a line.
---
 lib/PublicInbox/SearchView.pm | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/lib/PublicInbox/SearchView.pm b/lib/PublicInbox/SearchView.pm
index c789795..d038dfc 100644
--- a/lib/PublicInbox/SearchView.pm
+++ b/lib/PublicInbox/SearchView.pm
@@ -180,9 +180,8 @@ sub search_nav_top {
 sub search_nav_bot {
        my ($mset, $q) = @_;
        my $total = $mset->get_matches_estimated;
-       my $nr = scalar $mset->items;
        my $o = $q->{o};
-       my $end = $o + $nr;
+       my $end = $o + $mset->size;
        my $beg = $o + 1;
        my $rv = '</pre><hr><pre id=t>';
        if ($beg <= $end) {
-- 
EW

--
unsubscribe: meta+unsubscr...@public-inbox.org
archive: https://public-inbox.org/meta/

Reply via email to