Fixed merge and inserting.