diff options
author | flow <flowlnlnln@gmail.com> | 2022-06-20 08:55:35 -0300 |
---|---|---|
committer | flow <flowlnlnln@gmail.com> | 2022-07-17 11:33:43 -0300 |
commit | 5f75e531e61e1f2cb5d602e084e9a0ddd1c85a5c (patch) | |
tree | b6daf3f8a33d0718851cb3337f0f6e9674cb24c5 /launcher/modplatform/EnsureMetadataTask.cpp | |
parent | a7648d60ce1d1567cd1c878aaa55dae3696a0210 (diff) | |
download | PrismLauncher-5f75e531e61e1f2cb5d602e084e9a0ddd1c85a5c.tar.gz PrismLauncher-5f75e531e61e1f2cb5d602e084e9a0ddd1c85a5c.tar.bz2 PrismLauncher-5f75e531e61e1f2cb5d602e084e9a0ddd1c85a5c.zip |
fix: handling around disabled mods
Don't update disabled mods to prevent mod duplication. Also, chop
filename in the metadata with a '.disabled'.
Signed-off-by: flow <flowlnlnln@gmail.com>
Diffstat (limited to 'launcher/modplatform/EnsureMetadataTask.cpp')
-rw-r--r-- | launcher/modplatform/EnsureMetadataTask.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/launcher/modplatform/EnsureMetadataTask.cpp b/launcher/modplatform/EnsureMetadataTask.cpp index cf4e55b9..19e44ce0 100644 --- a/launcher/modplatform/EnsureMetadataTask.cpp +++ b/launcher/modplatform/EnsureMetadataTask.cpp @@ -455,6 +455,8 @@ void EnsureMetadataTask::modrinthCallback(ModPlatform::IndexedPack& pack, ModPla { // Prevent file name mismatch ver.fileName = mod.fileinfo().fileName(); + if (ver.fileName.endsWith(".disabled")) + ver.fileName.chop(9); QDir tmp_index_dir(m_index_dir); @@ -487,6 +489,8 @@ void EnsureMetadataTask::flameCallback(ModPlatform::IndexedPack& pack, ModPlatfo try { // Prevent file name mismatch ver.fileName = mod.fileinfo().fileName(); + if (ver.fileName.endsWith(".disabled")) + ver.fileName.chop(9); QDir tmp_index_dir(m_index_dir); |