You are here

function migrate_module_implements_alter in Migrate 7.2

Implements hook_module_implements_alter().

File

./migrate.module, line 615
API and drush commands to support migration of data from external sources into a Drupal installation.

Code

function migrate_module_implements_alter(&$implementation, $hook) {

  // Ensure that the Migration class exists, as different bootstrap phases may
  // not have included migration.inc yet.
  if (class_exists('Migration') && ($migration = Migration::currentMigration())) {
    $disable_hooks = $migration
      ->getDisableHooks();
    if (isset($disable_hooks[$hook])) {
      foreach ($disable_hooks[$hook] as $module) {
        unset($implementation[$module]);
      }
    }
  }
}