When restoring a file, a unique name needs to be generated if a file with the same name already exists. Also fixed the restore() method to return false if the file to restore does not exist. Added unit tests to cover restore cases.