From 45841f08991b9c69e05e88ae812ab88589bb34e6 Mon Sep 17 00:00:00 2001 From: vogelor Date: Sat, 1 May 2010 09:43:27 +0000 Subject: [PATCH] Added cleanup of the new sys_remoteaction - Table to the cron_daily.php --- server/cron_daily.php | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/server/cron_daily.php b/server/cron_daily.php index d173e2069..b5f7d1eea 100644 --- a/server/cron_daily.php +++ b/server/cron_daily.php @@ -221,7 +221,13 @@ if ($app->dbmaster == $app->db) { * if they are NOT ok, the server will try to process them in 1 minute and so the * error appears again after 1 minute. So it is no problem to delete the old one! */ - $sql = "DELETE FROM sys_log WHERE tstamp < $tstamp AND server_id != 0"; + $sql = "DELETE FROM sys_log WHERE tstamp < " . $tstamp . " AND server_id != 0"; + $app->dbmaster->query($sql); + + /* + * Delete all remote-actions "done" and older than 7 days + */ + $sql = "DELETE FROM sys_remoteaction WHERE tstamp < " . $tstamp . " AND action_status = 'ok'"; $app->dbmaster->query($sql); /* -- GitLab