You are here

function workbench_access_uninstall in Workbench Access 7

Remove our vocabulary and variables.

File

./workbench_access.install, line 214
Install file for Workbench Access.

Code

function workbench_access_uninstall() {
  if (module_exists('taxonomy')) {
    $vocabulary = taxonomy_vocabulary_machine_name_load('workbench_access');
    if (isset($vocabulary->vid)) {
      taxonomy_vocabulary_delete($vocabulary->vid);
    }
  }
  variable_del('workbench_access');
  db_delete('variable')
    ->condition('name', 'workbench_access_%', 'LIKE')
    ->execute();
}