Bug 6679 - Fixing code so it passes basic Perl:::Critic tests
authorMason James <mtj@kohaaloha.com>
Mon, 24 Sep 2012 23:21:43 +0000 (11:21 +1200)
committerBrendan A Gallagher <brendan@bywatersolutions.com>
Wed, 27 Jan 2016 05:06:23 +0000 (05:06 +0000)
opac/ilsdi.pl: Stricture disabled at line 217, column 17.  See page 429 of PBP.  (Severity: 5)

Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Mark Tompsett <mtompset@hotmail.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Brendan A Gallagher <brendan@bywatersolutions.com>
opac/ilsdi.pl

index c53acc6..05e7c5c 100755 (executable)
 # You should have received a copy of the GNU General Public License
 # along with Koha; if not, see <http://www.gnu.org/licenses>.
 
-use strict;
-use warnings;
-
-use List::MoreUtils qw(any);
+use Modern::Perl;
 
 use C4::ILSDI::Services;
 use C4::Auth;
 use C4::Output;
 use C4::Context;
+
+use List::MoreUtils qw(any);
 use XML::Simple;
 use CGI qw ( -utf8 );
 
@@ -217,7 +216,7 @@ if ( $service and any { $service eq $_ } @services ) {
 
             # Variable functions
             my $sub = do {
-                no strict 'refs';
+#                no strict 'refs';
                 my $symbol = 'C4::ILSDI::Services::' . $service;
                 \&{"$symbol"};
             };