1 node.install | node_update_1016() |
Ensure content type statuses are the correct published/unpublished value.
Related topics
File
- core/
modules/ node/ node.install, line 1178 - Install, update and uninstall functions for the node module.
Code
function node_update_1016() {
$types = config_get_names_with_prefix('node.type');
foreach ($types as $config_name) {
$config = config($config_name);
$status_default = $config->get('settings.status_default');
$config->set('settings.status_default', (int) $status_default);
$config->save();
}
}