From fd6755c93f3f3f7551f9b7c11d1bbbb48c22e210 Mon Sep 17 00:00:00 2001 From: flow Date: Sun, 19 Jun 2022 14:26:15 -0300 Subject: change: mod metadata improvements - Use slug instead of name - Keep temporary status before having local details Signed-off-by: flow --- launcher/ModDownloadTask.cpp | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'launcher/ModDownloadTask.cpp') diff --git a/launcher/ModDownloadTask.cpp b/launcher/ModDownloadTask.cpp index 7d35ff69..2b0343f4 100644 --- a/launcher/ModDownloadTask.cpp +++ b/launcher/ModDownloadTask.cpp @@ -47,10 +47,9 @@ void ModDownloadTask::downloadSucceeded() { m_filesNetJob.reset(); auto name = std::get<0>(to_delete); - if (!name.isEmpty()) { - // If they have the same name, we keep the metadata. - // This is a workaround for mods that change names between versions ;c - mods->uninstallMod(std::get<1>(to_delete), name == m_mod.name); + auto filename = std::get<1>(to_delete); + if (!name.isEmpty() && filename != m_mod_version.fileName) { + mods->uninstallMod(filename, true); } } -- cgit