Completed merge functionality and removed debug code. The "open file after merging" checkbox is now honored.