Fixing a few bugs and adding move / merge.