mirror of
https://github.com/packwiz/packwiz.git
synced 2025-05-02 02:36:29 +02:00
Fix modrinth update message (fixes #50)
This commit is contained in:
parent
7ac193eb87
commit
92ba8effaa
@ -64,9 +64,17 @@ func (u mrUpdater) CheckUpdate(mods []core.Mod, mcVersion string, pack core.Pack
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
|
newFilename := newVersion.Files[0].Filename
|
||||||
|
// Prefer the primary file
|
||||||
|
for _, v := range newVersion.Files {
|
||||||
|
if v.Primary {
|
||||||
|
newFilename = v.Filename
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
results[i] = core.UpdateCheck{
|
results[i] = core.UpdateCheck{
|
||||||
UpdateAvailable: true,
|
UpdateAvailable: true,
|
||||||
UpdateString: mod.FileName + " -> " + newVersion.Files[0].Filename,
|
UpdateString: mod.FileName + " -> " + newFilename,
|
||||||
CachedState: cachedStateStore{data.ModID, newVersion},
|
CachedState: cachedStateStore{data.ModID, newVersion},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user