You are here

function progress_cron in Background Process 8

Implements hook cron.

File

progress/progress.module, line 173
Progress framework for keeping track of progresses. @todo Force MyISAM for table {progress} to avoid transaction/isolation level problems, and use INSERT DELAYED for performance.

Code

function progress_cron() {
  return db_delete('progress')
    ->condition('end_stamp', 0, '>')
    ->condition('end_stamp', time() - \Drupal::config('progress.settings')
    ->get('progress_age'), '<')
    ->execute();
}