Skip to content

Commit

Permalink
Fix completed extraction counter missing most mods
Browse files Browse the repository at this point in the history
  • Loading branch information
mircearoata committed Dec 29, 2023
1 parent 4241cb6 commit 45e34cc
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions backend/bindings/ficsitcli/process.go
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,15 @@ func (f *FicsitCLI) validateInstall(installation *InstallationInfo, progressItem

go func() {
for update := range installChannel {
if update.Type == cli.InstallUpdateTypeOverall {
// Although this wouldn't cause any issues in the progress generation above, we can ignore this update.
continue
}
modProgresses.Compute(update.Item.Mod, func(oldValue modProgress, loaded bool) (modProgress, bool) {
if oldValue.complete {
// Sometimes extract updates are received after the mod is marked as complete.
return oldValue, false
}
oldValue.complete = update.Type == cli.InstallUpdateTypeModComplete
oldValue.downloading = update.Type == cli.InstallUpdateTypeModDownload

Expand Down

0 comments on commit 45e34cc

Please sign in to comment.