You are here

function hansel_features_revert in Hansel breadcrumbs 7

Same name and namespace in other branches
  1. 8 hansel.features.inc \hansel_features_revert()

Implements hook_features_revert().

File

./hansel.features.inc, line 49

Code

function hansel_features_revert($module_name) {
  module_load_include('inc', 'hansel', 'hansel.export');
  $config = module_invoke($module_name, 'hansel_default');
  if (!empty($config)) {
    foreach ($config as $element => $object) {
      switch ($element) {
        case 'config':
          hansel_import_config($object);
          break;
        case 'settings':
          hansel_import_settings($object);
          break;
      }
    }
  }
}