Move disk check below directory creation

This commit is contained in:
Unnoen 2021-02-04 21:05:33 +11:00
parent cf29bae7a7
commit 14cb675e3e
No known key found for this signature in database
GPG Key ID: 8F8E42252BA20553

View File

@ -56,8 +56,6 @@ namespace Wabbajack.Lib
await Metrics.Send(Metrics.BeginInstall, ModList.Name);
Utils.Log("Configuring Processor");
if (new PhysicalDisk(OutputFolder.DriveInfo().Name).MediaType == PhysicalDisk.MediaTypes.HDD && ReduceHDDThreads) DesiredThreads.OnNext(1); else DesiredThreads.OnNext(DiskThreads);
FileExtractor2.FavorPerfOverRAM = FavorPerfOverRam;
if (GameFolder == null)
@ -120,13 +118,13 @@ namespace Wabbajack.Lib
}
}
// Reduce to one thread if downloads on HDD, else use specified. Hashing on HDD has no benefit with more threads.
if (new PhysicalDisk(DownloadFolder.DriveInfo().Name).MediaType == PhysicalDisk.MediaTypes.HDD && ReduceHDDThreads) DesiredThreads.OnNext(1); else DesiredThreads.OnNext(DiskThreads);
if (cancel.IsCancellationRequested) return false;
UpdateTracker.NextStep("Optimizing ModList");
await OptimizeModlist();
// Reduce to one thread if downloads on HDD, else use specified. Hashing on HDD has no benefit with more threads.
if (new PhysicalDisk(DownloadFolder.DriveInfo().Name).MediaType == PhysicalDisk.MediaTypes.HDD && ReduceHDDThreads) DesiredThreads.OnNext(1); else DesiredThreads.OnNext(DiskThreads);
if (cancel.IsCancellationRequested) return false;
UpdateTracker.NextStep("Hashing Archives");
await HashArchives();