Fixup the code to merge during path walks