default_content.module 419 Bytes
Newer Older
larowlan's avatar
larowlan committed
1 2
<?php

larowlan's avatar
larowlan committed
3 4 5 6 7
/**
 * @file
 * Installs default content on the behalf of modules at time of install.
 */

8 9 10 11 12 13 14
/**
 * Implements hook_modules_installed().
 */
function default_content_modules_installed($modules) {
  // @todo Move this to an event once we have HookEvent.
  foreach ($modules as $module) {
    if (!\Drupal::isConfigSyncing()) {
15
      \Drupal::service('default_content.importer')->importContent($module);
16 17 18
    }
  }
}