Added function to move old data to a cache folder instead of deleting it