mirror of
https://github.com/bloxstraplabs/bloxstrap.git
synced 2025-05-13 19:54:41 -07:00
Fix uninstallation not cleaning up properly
This commit is contained in:
parent
8ffb22c4f9
commit
d72f835ad1
@ -285,6 +285,7 @@ namespace Bloxstrap
|
||||
|
||||
() => Directory.Delete(Paths.Downloads, true),
|
||||
() => Directory.Delete(Paths.Roblox, true),
|
||||
() => Directory.Delete(Paths.Icons, true),
|
||||
|
||||
() => File.Delete(App.State.FileLocation)
|
||||
};
|
||||
@ -300,13 +301,7 @@ namespace Bloxstrap
|
||||
});
|
||||
}
|
||||
|
||||
bool deleteFolder = false;
|
||||
|
||||
if (Directory.Exists(Paths.Base))
|
||||
{
|
||||
var folderFiles = Directory.GetFiles(Paths.Base);
|
||||
deleteFolder = folderFiles.Length == 1 && folderFiles.First().EndsWith(".exe", StringComparison.InvariantCultureIgnoreCase);
|
||||
}
|
||||
bool deleteFolder = Directory.GetFiles(Paths.Base).Length <= 3;
|
||||
|
||||
if (deleteFolder)
|
||||
cleanupSequence.Add(() => Directory.Delete(Paths.Base, true));
|
||||
|
Loading…
Reference in New Issue
Block a user