working on the actual merging