Commit be926c5b authored by Darren Oh's avatar Darren Oh Committed by Alex Andrascu

Issue #2290707 by DamienMcKenna, mitsuroseba, Darren Oh: Exclude the data from...

Issue #2290707 by DamienMcKenna, mitsuroseba, Darren Oh: Exclude the data from the following tables - does not work
parent f6da8114
......@@ -214,6 +214,25 @@ class backup_migrate_profile extends backup_migrate_item {
var $title_plural = 'Settings Profiles';
var $title_singular = 'Settings Profile';
/**
* Perform a shallow merge of the defaults and the parameters.
*
* This is needed because otherwise it will *combine* the nested arrays and
* make it impossible to deselect database tables from the 'nodata' setting.
*
* @param array $params
*/
public function __construct(array $params = array()) {
$params = (array)$params;
$defaults = (array)$this->get_default_values();
foreach ($defaults as $key => $val) {
if (!isset($params[$key])) {
$params[$key] = $val;
}
}
$this->from_array($params);
}
/**
* This function is not supposed to be called. It is just here to help the po extractor out.
*/
......
......@@ -108,7 +108,7 @@ class backup_migrate_source_db extends backup_migrate_source_remote {
}
return array(
'nodata_tables' => array_merge($basic, $cache, module_invoke_all('devel_caches')),
'nodata_tables' => drupal_map_assoc(array_merge($basic, $cache, module_invoke_all('devel_caches'))),
'exclude_tables' => $simpletest,
'utils_lock_tables' => FALSE,
);
......
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