Bugzilla – Attachment 45156 Details for
Bug 15217
variables declared twice in in catalogue/search.pl
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 15217 Remove redundant duplicate var declaration
Bug-15217-Remove-redundant-duplicate-var-declarati.patch (text/plain), 1.94 KB, created by
Frédéric Demians
on 2015-11-25 16:11:16 UTC
(
hide
)
Description:
Bug 15217 Remove redundant duplicate var declaration
Filename:
MIME Type:
Creator:
Frédéric Demians
Created:
2015-11-25 16:11:16 UTC
Size:
1.94 KB
patch
obsolete
>From c7896b9cb59064e30bc08671ca6f9e05b401fb67 Mon Sep 17 00:00:00 2001 >From: Colin Campbell <colin.campbell@ptfs-europe.com> >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=UTF-8 >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 <f.demians@tamil.fr> > As suggested by Colin, perl -wc catalogue/search.pl doesn't complain > anymore after applying the patch. perlcritic confirms the 2 variables > were unused. >--- > catalogue/search.pl | 4 ---- > 1 file changed, 4 deletions(-) > >diff --git a/catalogue/search.pl b/catalogue/search.pl >index e74ceca..ef0bc8c 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.6.2
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 15217
:
45016
|
45017
|
45156
|
45208
|
46056