Fix updater not always cleaning up temp directory

Updater was only deleting TempUpdate folder when an error occured.
This commit is contained in:
Dentomologist 2020-11-13 12:25:53 -08:00
parent 8a621c2d5e
commit 6dcf7643e5

View file

@ -755,10 +755,10 @@ bool RunUpdater(std::vector<std::string> args)
UI::SetDescription("Performing Update...");
bool ok = PerformUpdate(todo, opts.install_base_path, opts.content_store_url, temp_dir);
CleanUpTempDir(temp_dir, todo);
if (!ok)
{
FatalError("Failed to apply the update.");
CleanUpTempDir(temp_dir, todo);
return false;
}