diff --git a/cron/cleanup.php b/cron/cleanup.php index 2e0bce6..2f6d628 100644 --- a/cron/cleanup.php +++ b/cron/cleanup.php @@ -251,9 +251,10 @@ function orphanSessionListCheck() $hResult = query_parameters($sQuery, SESSION_DAYS_TO_EXPIRE + 2); } +// report the database error log entries to the mailing list function reportErrorLogEntries() { - error_log::mail_admins_error_log(); + error_log::mail_admins_error_log($sEmailSubject); error_log::flush(); } diff --git a/include/error_log.php b/include/error_log.php index 4d12e3b..abb312a 100644 --- a/include/error_log.php +++ b/include/error_log.php @@ -60,9 +60,9 @@ class error_log else return false; } - function mail_admins_error_log() + function mail_admins_error_log($sSubject = "") { - $sSubject = "Appdb error log\r\n"; + $sSubject .= "Database Error log\r\n"; $sEmail = User::get_notify_email_address_list(null, null); /* get list admins */ $sQuery = "SELECT * from error_log WHERE deleted='0' ORDER BY submitTime";