You are here

function ultimate_cron_cron_queue_info in Ultimate Cron 7

Same name and namespace in other branches
  1. 8 ultimate_cron.module \ultimate_cron_cron_queue_info()
  2. 7.2 ultimate_cron.module \ultimate_cron_cron_queue_info()

Implements hook_cron_queue_info(). Used for code injection in order to hijack cron runs.

File

./ultimate_cron.module, line 222
@todo Add filter on overview page. @todo Add log view (with graph). @todo Make proper markup for overview page. @todo Refactor drush stuff, too many intimate relations with Background Process @todo Refactor Cron % offset stuff. Too mixed up and…

Code

function ultimate_cron_cron_queue_info() {
  static $processed = FALSE;
  if (!$processed) {
    $processed = TRUE;
    if (basename($_SERVER['PHP_SELF']) == 'cron.php') {
      ultimate_cron_cron_run(FALSE);
      exit;
    }
  }
  return array();
}