Safer header copy

The old method would replace objects one past one level deep instead of merging them. This method assumes a dictionary of dictionaries and runs the update() call one layer in instead of the root, which has the effect of preserving both sets of headers.