From 866806997f4cbb018062c0b1eb12381940d44962 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Tue, 31 Jul 2018 08:21:00 -0300 Subject: [PATCH] Bug 19604: Fix perlcritic "Loop iterator is not lexical" Loop iterator is not lexical at line 318, column 13. See page 108 of PBP. (Severity: 5) Signed-off-by: Tomas Cohen Arazi (cherry picked from commit 4d45bd575569880676a212655d3d747f368697e4) Signed-off-by: Martin Renvoize --- Koha/SearchEngine/Elasticsearch/QueryBuilder.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm index 5c24d3cefd..40c88b9dad 100644 --- a/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm +++ b/Koha/SearchEngine/Elasticsearch/QueryBuilder.pm @@ -315,8 +315,8 @@ sub build_authorities_query { # regular wordlist stuff # push @query_parts, { match => {$wh => { query => $val, operator => 'and' }} }; my @values = split(' ',$val); - foreach $val (@values) { - push @query_parts, { wildcard => { "$wh.phrase" => "*" . lc $val . "*" } }; + foreach my $v (@values) { + push @query_parts, { wildcard => { "$wh.phrase" => "*" . lc $v . "*" } }; } } } -- 2.39.5