Revert "Bug 6554: Followup for preferences.pl"
[koha.git] / misc / cronjobs / services_throttle.pl
blobcafc5171cf9a6cdd173208b3374ae9d0b215cd43
1 #!/usr/bin/perl
2 # run nightly -- resets the xisbn services throttle
4 use strict;
5 use warnings;
7 BEGIN {
8 # find Koha's Perl modules
9 # test carefully before changing this
10 use FindBin;
11 eval { require "$FindBin::Bin/../kohalib.pl" };
14 use C4::Context;
15 my $fixit="UPDATE services_throttle SET service_count=0 WHERE service_type='xisbn'";
16 my $sth = C4::Context->dbh->prepare($fixit);
17 my $res = $sth->execute() or die "cannot execute query: $fixit";
19 # There is no need to return anything if we succeeded,
20 # and the die message (or other more internal Context/mysql error)
21 # will get emailed to the cron user if we didn't.