Fixed add node to the end of merged head.