ffzg/recall_notices.pl: added --interval and --dedup
[koha.git] / opac / opac-tags_subject.pl
index d879d51..b083ef2 100755 (executable)
@@ -24,15 +24,13 @@ TODO :: Description here
 
 =cut
 
-use strict;
-use warnings;
+use Modern::Perl;
 
 use C4::Auth;
 use C4::Context;
 use C4::Output;
 use CGI qw ( -utf8 );
 use C4::Biblio;
-use C4::Koha;       # use getitemtypeinfo
 
 my $query = new CGI;
 
@@ -51,8 +49,8 @@ my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
 
 my $number = $query->param('number') || 100;
 
-my $sth = $dbh->prepare("SELECT entry,weight FROM tags ORDER BY weight DESC LIMIT $number");
-$sth->execute;
+my $sth = $dbh->prepare("SELECT entry,weight FROM tags ORDER BY weight DESC LIMIT ?");
+$sth->execute($number);
 
 my %result;
 my $max=0;