You are here

function forum_uninstall in Drupal 7

Same name and namespace in other branches
  1. 8 core/modules/forum/forum.install \forum_uninstall()
  2. 5 modules/forum/forum.install \forum_uninstall()
  3. 6 modules/forum/forum.install \forum_uninstall()
  4. 9 core/modules/forum/forum.install \forum_uninstall()

Implements hook_uninstall().

File

modules/forum/forum.install, line 105
Install, update, and uninstall functions for the Forum module.

Code

function forum_uninstall() {

  // Load the dependent Taxonomy module, in case it has been disabled.
  drupal_load('module', 'taxonomy');
  variable_del('forum_containers');
  variable_del('forum_hot_topic');
  variable_del('forum_per_page');
  variable_del('forum_order');
  variable_del('forum_block_num_active');
  variable_del('forum_block_num_new');
  variable_del('node_options_forum');
  field_delete_field('taxonomy_forums');

  // Purge field data now to allow taxonomy module to be uninstalled
  // if this is the only field remaining.
  field_purge_batch(10);
}