You are here

function pmpapi_permissions_uninstall in Public Media Platform API Integration 7

Implements hook_uninstall().

File

pmpapi_permissions/pmpapi_permissions.install, line 11
Install, update and uninstall functions for the pmpapi_permissions module.

Code

function pmpapi_permissions_uninstall() {
  module_load_include('module', 'pmpapi_push');
  module_load_include('module', 'pmpapi');
  foreach (pmpapi_push_get_entities() as $entity_type => $entity) {
    foreach ($entity['bundles'] as $bundle_name => $bundle) {
      $uname = $entity_type . '__' . $bundle_name;
      variable_del('pmpapi_permissions_default_group_' . $uname);
      variable_del('pmpapi_permissions_default_list_type_' . $uname);
    }
  }
}