diff --git a/TS SE Tool/Forms/FormMainControlsMethods.cs b/TS SE Tool/Forms/FormMainControlsMethods.cs index ca18a04..c92c51b 100644 --- a/TS SE Tool/Forms/FormMainControlsMethods.cs +++ b/TS SE Tool/Forms/FormMainControlsMethods.cs @@ -335,21 +335,26 @@ private void buttonProfilesAndSavesRestoreBackup_Click(object sender, EventArgs if (dr == DialogResult.Cancel) return; + string SiiInfoPath = Globals.SelectedSavePath + @"\info.sii", + SiiInfoPathBackup = Globals.SelectedSavePath + @"\info_backup.sii"; + if (dr == DialogResult.No) { SwapFiles(SiiSavePath, SiiSavePathBackup); - string SiiInfoPath = Globals.SelectedSavePath + @"\info.sii", - SiiInfoPathBackup = Globals.SelectedSavePath + @"\info_backup.sii"; - if (File.Exists(SiiInfoPathBackup)) SwapFiles(SiiInfoPath, SiiInfoPathBackup); } else { File.Copy(SiiSavePathBackup, SiiSavePath, true); - File.Delete(SiiSavePathBackup); + + if (File.Exists(SiiInfoPathBackup)) + { + File.Copy(SiiInfoPathBackup, SiiInfoPath, true); + File.Delete(SiiInfoPathBackup); + } } void SwapFiles(string _firstFile, string _secondFile)