saving stuff before merging