Don't try to remove non-existent dir.

This commit is contained in:
Lauri Kenttä
2024-01-20 12:43:00 +02:00
parent 1a5b1df064
commit 39596aadfc

View File

@@ -596,7 +596,9 @@ public class Setup {
protected void Uninstall() {
Disable();
try {
Directory.Delete(InstallPath, true);
if (Directory.Exists(InstallPath)) {
Directory.Delete(InstallPath, true);
}
WriteLine($"HackBGRT has been removed from {InstallPath}.");
} catch (Exception e) {
Log($"Uninstall failed: {e.ToString()}");