From 558f291465d60c082c0e9a4a15eb7ed87a3e3fde Mon Sep 17 00:00:00 2001 From: Colin Campbell Date: Thu, 19 Nov 2015 14:17:10 +0000 Subject: [PATCH] Bug 15217 Remove redundant duplicate var declaration MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit remove superfluous second declaration of template, borrowernumber and cookie which are never used Also removed the variables @results and @results_array which are declared but not used Signed-off-by: Frédéric Demians As suggested by Colin, perl -wc catalogue/search.pl doesn't complain anymore after applying the patch. perlcritic confirms the 2 variables were unused. Signed-off-by: Katrin Fischer Signed-off-by: Brendan A Gallagher --- catalogue/search.pl | 4 ---- 1 file changed, 4 deletions(-) diff --git a/catalogue/search.pl b/catalogue/search.pl index e74ceca11d..ef0bc8cbb7 100755 --- a/catalogue/search.pl +++ b/catalogue/search.pl @@ -162,7 +162,6 @@ my $DisplayMultiPlaceHold = C4::Context->preference("DisplayMultiPlaceHold"); use CGI qw('-no_undef_params' -utf8 ); my $cgi = new CGI; -my ($template,$borrowernumber,$cookie); # decide which template to use my $template_name; my $template_type; @@ -484,8 +483,6 @@ my $expanded_facet = $params->{'expand'}; # Define some global variables my ( $error,$query,$simple_query,$query_cgi,$query_desc,$limit,$limit_cgi,$limit_desc,$stopwords_removed,$query_type); -my @results; - ## I. BUILD THE QUERY ( $error,$query,$simple_query,$query_cgi,$query_desc,$limit,$limit_cgi,$limit_desc,$stopwords_removed,$query_type) = buildQuery(\@operators,\@operands,\@indexes,\@limits,\@sort_by,$scan,$lang); @@ -526,7 +523,6 @@ $template->param ( LIMIT_INPUTS => \@limit_inputs ); ## II. DO THE SEARCH AND GET THE RESULTS my $total; # the total results for the whole set my $facets; # this object stores the faceted results that display on the left-hand of the results page -my @results_array; my $results_hashref; eval { -- 2.39.5