diff --git a/includes/webform.components.inc b/includes/webform.components.inc index f254731..e1faacc 100644 --- a/includes/webform.components.inc +++ b/includes/webform.components.inc @@ -848,6 +848,7 @@ function webform_component_delete($node, $component) { /** * Recursively insert components into the database. + * * @param $node * The node object containing the current webform. * @param $component @@ -855,8 +856,9 @@ function webform_component_delete($node, $component) { */ function webform_component_clone(&$node, &$component) { $original_cid = $component['cid']; - unset($component['cid']); + $component['cid'] = NULL; $new_cid = webform_component_insert($component); + $component['cid'] = $new_cid; if (webform_component_feature($component['type'], 'group')) { foreach ($node->webform['components'] as $cid => $child_component) { if ($child_component['pid'] == $original_cid) {