function social_install_tasks in Open Social 10.1.x
Same name and namespace in other branches
- 8.9 social.profile \social_install_tasks()
- 8 social.profile \social_install_tasks()
- 8.2 social.profile \social_install_tasks()
- 8.3 social.profile \social_install_tasks()
- 8.4 social.profile \social_install_tasks()
- 8.5 social.profile \social_install_tasks()
- 8.6 social.profile \social_install_tasks()
- 8.7 social.profile \social_install_tasks()
- 8.8 social.profile \social_install_tasks()
- 10.3.x social.profile \social_install_tasks()
- 10.0.x social.profile \social_install_tasks()
- 10.2.x social.profile \social_install_tasks()
Implements hook_install_tasks().
File
- ./
social.profile, line 14 - Enables modules and site configuration for a social site installation.
Code
function social_install_tasks(&$install_state) {
$tasks = [];
// If the user has selected that demo content should be installed then we add
// this as an extra install step.
if (\Drupal::state()
->get('social_install_demo_content', 0) === 1) {
$tasks['social_install_demo_content'] = [
'display_name' => t('Install demo content'),
'display' => TRUE,
'type' => 'batch',
];
}
return $tasks;
}