Skip to content

Commit

Permalink
Fix ioexception
Browse files Browse the repository at this point in the history
  • Loading branch information
Laeng committed Oct 11, 2023
1 parent b188076 commit 4b94fb3
Showing 1 changed file with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -69,15 +69,10 @@ public InstallStatus Install(string zipFileName, string destinationFolder)
}

var userConifgPath = Path.Combine(destinationFolder, "user.cfg");

if (!File.Exists(userConifgPath))
{
File.Create(userConifgPath);
}

var userConfig = new ConfigParser(userConifgPath);

userConfig.SetValue("shatagon", "g_language", "korean_(south_korea)"); //FIXME - 추후 다국어 지원을 위해서는 편집이 필요하다.
userConfig.SetValue("Localization", "g_language", "korean_(south_korea)"); //FIXME - 추후 다국어 지원을 위해서는 편집이 필요하다.
userConfig.Save();

}
catch (CryptographicException e)
Expand Down Expand Up @@ -145,6 +140,11 @@ public LocalizationInstallationType GetInstallationType(string destinationFolder
return LocalizationInstallationType.None;
}

if (!Directory.Exists(Path.Combine(destinationFolder, "data")))
{
return LocalizationInstallationType.None;
}

var userConifgPath = Path.Combine(destinationFolder, "user.cfg");

if (!File.Exists(userConifgPath))
Expand Down

0 comments on commit 4b94fb3

Please sign in to comment.