Commit 39919938 authored by matslats's avatar matslats

hook_install will now run importContent on all modules already installed

parent 4a3dd4c0
......@@ -5,6 +5,17 @@
* Installs default content on the behalf of modules at time of install.
*/
/**
* Implements hook_install().
* check all existing modules for imported content()
*/
function default_content_install() {
foreach (\Drupal::moduleHandler()->getModuleList() as $module => $null) {
\Drupal::service('default_content.manager')->importContent($module);
}
}
/**
* Implements hook_modules_installed().
*/
......@@ -16,3 +27,5 @@ function default_content_modules_installed($modules) {
}
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment