From 9226ae46419a5c54447c7d6e27b6163d2c6fd95a Mon Sep 17 00:00:00 2001 From: Mason James Date: Wed, 18 Jul 2012 14:04:50 +1200 Subject: [PATCH] Bug 8463 - Koha/SearchEngine/Solr/Search.pm fails perlcritic test modified: Koha/SearchEngine/Solr/Search.pm Signed-off-by: Jonathan Druart Signed-off-by: Paul Poulain --- Koha/SearchEngine/Solr/Search.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Koha/SearchEngine/Solr/Search.pm b/Koha/SearchEngine/Solr/Search.pm index 5c626ba8c8..b177ca43ae 100644 --- a/Koha/SearchEngine/Solr/Search.pm +++ b/Koha/SearchEngine/Solr/Search.pm @@ -38,7 +38,8 @@ sub search { ) : ( "recordid", "id" ); - my $recordtype = ref($filters->{recordtype}) eq 'ARRAY' + my $recordtype; + $recordtype = ref($filters->{recordtype}) eq 'ARRAY' ? $filters->{recordtype}[0] : $filters->{recordtype} if defined $filters && defined $filters->{recordtype}; -- 2.20.1