You are here

semiclean.module in Semiclean 8

Same filename and directory in other branches
  1. 6 semiclean.module
  2. 7 semiclean.module

Utility module for cleaning up after failed cron jobs.

File

semiclean.module
View source
<?php

/**
 * @file
 * Utility module for cleaning up after failed cron jobs.
 */

/**
 * Implements hook_menu().
 */
function semiclean_menu() {
  return array(
    'admin/reports/status/semiclean' => array(
      'title' => 'Semiclean',
      'access arguments' => array(
        'administer site configuration',
      ),
      'page callback' => '_semiclean_do_your_magic',
      'type' => MENU_CALLBACK,
    ),
  );
}

/**
 * Menu callback to delete the cron semaphore.
 */
function _semiclean_do_your_magic() {
  drupal_cron_cleanup();
  drupal_set_message(t('Cron semaphore cleaned.'), 'status');
  drupal_goto('admin/reports/status');
}

Functions

Namesort descending Description
semiclean_menu Implements hook_menu().
_semiclean_do_your_magic Menu callback to delete the cron semaphore.