You are here

function mail_logger_cron in Mail Logger 7

Implements hook_cron().

File

./mail_logger.module, line 332
Mail Logger module logs all outgoing mail that passes through the drupal_mail function.

Code

function mail_logger_cron() {
  $log_maximum_age = variable_get('mail_logger_log_maximum_age', 0);
  if ($log_maximum_age > 0) {
    db_delete('mail_logger')
      ->condition('date_sent', REQUEST_TIME - $log_maximum_age, '<')
      ->execute();
  }
}