Metadata should probably be added before the other data is merged in, since user-defined data is more relevant.

I'd also suggest using `ArrayUtils::merge()` (because of the handling of numerically indexed arrays)