/// <summary>Restores a backup of a file.</summary> /// <param name="settings">The settings we want to use to override the default settings.</param> /// <returns>True if a backup was restored, or False if no backup could be found.</returns> public static bool RestoreBackup(ES3Settings settings) { var backupSettings = new ES3Settings(settings.path + backupFileSuffix, settings); if (!FileExists(backupSettings)) { return(false); } ES3.RenameFile(backupSettings, settings); return(true); }
public override void Enter() { ES3.RenameFile(oldFilePath.Value, newFilePath.Value, GetSettings(), GetSettings()); }