| | |
| | | try { |
| | | var backuplist = IO.FileUtils.ReadFiles (); |
| | | int index = 0; |
| | | string oldRegionRootPath = IO.FileUtils.CreateRegionBackup (UserConfig.Instance.CurrentRegion.Name); |
| | | string oldRegionRootPath = IO.FileUtils.CreateRegionBackup (UserConfig.Instance.CurrentRegion.Id); |
| | | IO.FileUtils.DeleteRegionFiles (oldRegionRootPath); |
| | | foreach (var fileName in backuplist) { |
| | | System.IO.FileInfo fileInfo = new System.IO.FileInfo (IO.FileUtils.RootPath + fileName); |
| | |
| | | }); |
| | | } |
| | | IO.FileUtils.DeleteAllFile (); |
| | | string newRegionRootPath = IO.FileUtils.CreateRegionBackup (homeTemp.Name); |
| | | string newRegionRootPath = IO.FileUtils.CreateRegionBackup (homeTemp.Id); |
| | | IO.FileUtils.RestoreRegionFiles (newRegionRootPath); |
| | | UserConfig.Instance.RefreshUserConfig (); |
| | | UserConfig.Instance.CurrentRegion = homeTemp; |