function history_cron

Same name in other branches
  1. 9 core/modules/history/history.module \history_cron()
  2. 8.9.x core/modules/history/history.module \history_cron()

Implements hook_cron().

File

core/modules/history/history.module, line 129

Code

function history_cron() {
    \Drupal::database()->delete('history')
        ->condition('timestamp', HISTORY_READ_LIMIT, '<')
        ->execute();
}

Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.