2007-07-11 15:15:40 +00:00
|
|
|
<?php
|
|
|
|
// $Id$
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Implementation of hook_install().
|
|
|
|
*/
|
|
|
|
function update_install() {
|
|
|
|
// Create cache table.
|
|
|
|
drupal_install_schema('update');
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Implementation of hook_uninstall().
|
|
|
|
*/
|
|
|
|
function update_uninstall() {
|
|
|
|
// Remove cache table.
|
|
|
|
drupal_uninstall_schema('update');
|
|
|
|
// Clear any variables that might be in use
|
|
|
|
$variables = array(
|
|
|
|
'update_check_frequency',
|
|
|
|
'update_fetch_url',
|
|
|
|
'update_last_check',
|
|
|
|
'update_notification_threshold',
|
|
|
|
'update_notify_emails',
|
|
|
|
);
|
|
|
|
foreach ($variables as $variable) {
|
|
|
|
variable_del($variable);
|
|
|
|
}
|
|
|
|
menu_rebuild();
|
|
|
|
}
|
2007-10-05 14:43:26 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Implementation of hook_schema().
|
|
|
|
*/
|
|
|
|
function update_schema() {
|
|
|
|
$schema['cache_update'] = drupal_get_schema_unprocessed('system', 'cache');
|
|
|
|
return $schema;
|
|
|
|
}
|
|
|
|
|