View | Details | Raw Unified | Return to bug 12760
Collapse All | Expand All

(-)a/misc/cronjobs/cleanup_database.pl (-3 / +1 lines)
Lines 128-134 unless ( $sessions Link Here
128
}
128
}
129
129
130
my $dbh = C4::Context->dbh();
130
my $dbh = C4::Context->dbh();
131
my $query;
132
my $sth;
131
my $sth;
133
my $sth2;
132
my $sth2;
134
my $count;
133
my $count;
Lines 181-187 if ($mail) { Link Here
181
180
182
    $sth = $dbh->prepare("DELETE FROM message_queue WHERE time_queued < date_sub(curdate(), interval ? day)");
181
    $sth = $dbh->prepare("DELETE FROM message_queue WHERE time_queued < date_sub(curdate(), interval ? day)");
183
    $sth->execute($mail) or die $dbh->errstr;
182
    $sth->execute($mail) or die $dbh->errstr;
184
    my $count = $sth->rows;
183
    $count = $sth->rows;
185
    $sth->finish;
184
    $sth->finish;
186
185
187
    print "$count messages were deleted from the mail queue.\nDone with message_queue purge.\n" if ($verbose);
186
    print "$count messages were deleted from the mail queue.\nDone with message_queue purge.\n" if ($verbose);
188
- 

Return to bug 12760