diff options
author | Eric Wong <e@80x24.org> | 2021-10-16 01:01:02 +0000 |
---|---|---|
committer | Eric Wong <e@80x24.org> | 2021-10-16 01:42:55 +0000 |
commit | 48cfcb04ed337f96e5105a2f93d127d2d6692c5a (patch) | |
tree | a5d28139b7ca9f01d17b253073d2564b1cca280f /lib/PublicInbox/Search.pm | |
parent | d7511a5d9eeea403a39d25ff3da10f51b46eb728 (diff) | |
download | public-inbox-48cfcb04ed337f96e5105a2f93d127d2d6692c5a.tar.gz |
Some yak-shaving while I try to track down other bugs...
Diffstat (limited to 'lib/PublicInbox/Search.pm')
-rw-r--r-- | lib/PublicInbox/Search.pm | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/lib/PublicInbox/Search.pm b/lib/PublicInbox/Search.pm index 145fb56c..600e6400 100644 --- a/lib/PublicInbox/Search.pm +++ b/lib/PublicInbox/Search.pm @@ -5,6 +5,7 @@ # Read-only search interface for use by the web and NNTP interfaces package PublicInbox::Search; use strict; +use v5.10.1; use parent qw(Exporter); our @EXPORT_OK = qw(retry_reopen int_val get_pct xap_terms); use List::Util qw(max); @@ -398,12 +399,10 @@ sub retry_reopen { my ($self, $cb, @arg) = @_; for my $i (1..10) { if (wantarray) { - my @ret; - eval { @ret = $cb->($self, @arg) }; + my @ret = eval { $cb->($self, @arg) }; return @ret unless $@; } else { - my $ret; - eval { $ret = $cb->($self, @arg) }; + my $ret = eval { $cb->($self, @arg) }; return $ret unless $@; } # Exception: The revision being read has been discarded - |