function _configuration_track_dependencies in Configuration Management 7
3 calls to _configuration_track_dependencies()
- configuration_delete_multiple in ./
configuration.module - Delete a specific configuration from being tracked.
- configuration_download_diff in ./
configuration.admin.inc - Download a unified diff.
- configuration_write_exports in ./
configuration.export.inc - Writes configurations to disk.
File
- ./
configuration.export.inc, line 779
Code
function _configuration_track_dependencies($export) {
// Check if there are any configurations in this export that isn't being tracked.
$save_also = array();
if (isset($export['configuration_dependency']) && !empty($export['configuration_dependency'])) {
foreach ($export['configuration_dependency']['configuration'] as $component => $info) {
foreach ($info as $name => $parent) {
if (!configuration_is_tracked($component, $name)) {
$save_also[$component][$name] = array(
'parent' => $parent,
'modules' => $export['configuration_dependency']['modules'][$component][$name],
);
}
else {
db_update('config_export')
->fields(array(
'parent' => $parent,
))
->condition('name', $name)
->execute();
}
}
}
}
if (!empty($save_also)) {
configuration_save($save_also);
}
}