You are here

function ldapgroups_uninstall in LDAP integration 6

Same name and namespace in other branches
  1. 5 ldapgroups.install \ldapgroups_uninstall()

Implementation of hook_uninstall().

File

./ldapgroups.install, line 99
ldapgroups module installation and upgrade code.

Code

function ldapgroups_uninstall() {

  // We're removing fileds from an existing table, not deleting a whole one.
  $ret = array();
  if (db_table_exists('ldapauth')) {
    db_drop_field($ret, 'ldapauth', 'ldapgroups_in_dn');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_dn_attribute');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_attr');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_in_attr');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_as_entries');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_entries');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_entries_attribute');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_mappings');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_mappings_filter');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_filter_php');
    db_drop_field($ret, 'ldapauth', 'ldapgroups_groups');
  }
  return $ret;
}