]> git.ipfire.org Git - thirdparty/public-inbox.git/commitdiff
searchidx: drop redundant decl in index_git_blob_id
authorEric Wong <e@80x24.org>
Tue, 5 Dec 2023 09:46:22 +0000 (09:46 +0000)
committerEric Wong <e@80x24.org>
Tue, 5 Dec 2023 22:05:10 +0000 (22:05 +0000)
Oddly, Perl did not warn about this.  Spotted while confirming
abbreviated OIDs are also indexed when unabbreviated OIDs
appear.

lib/PublicInbox/SearchIdx.pm

index 86c435fde1d8124c8386245e37a590d40cd7e696..1bf471fcd28bef7854f39e94a58f564a63a51d3e 100644 (file)
@@ -715,7 +715,6 @@ sub nr_quiet_rm { delete($_[0]->{-quiet_rm}) // 0 }
 sub index_git_blob_id {
        my ($doc, $pfx, $objid) = @_;
 
-       my $len = length($objid);
        for (my $len = length($objid); $len >= 7; ) {
                $doc->add_term($pfx.$objid);
                $objid = substr($objid, 0, --$len);