You are here

function features_feature_unlock in Features 7.2

Unlocks a feature or its component.

Parameters

string $feature: A (feature) module name.

string|null $component: (optional) A component name, e.g. 'field_instance'.

2 calls to features_feature_unlock()
features_admin_lock in ./features.admin.inc
Page callback to lock or unlock a component.
features_feature_lock_confirm_form_submit in ./features.admin.inc
Submit callback to lock components of a feature.

File

./features.module, line 1506
Main *.module file for the 'features' module.

Code

function features_feature_unlock($feature, $component = NULL) {
  $locked = variable_get('features_feature_locked', array());
  if ($component) {
    unset($locked[$feature][$component]);
  }
  else {
    unset($locked[$feature]['_all']);
  }
  variable_set('features_feature_locked', $locked);
}