feat: allow disabling mod metadata usage

This commit is contained in:
flow
2022-04-17 10:19:23 -03:00
committed by flow
parent 23febc6d94
commit 4439666e67
8 changed files with 107 additions and 40 deletions

View File

@ -124,7 +124,11 @@ bool Mod::enable(bool value)
bool Mod::destroy(QDir& index_dir)
{
Metadata::remove(index_dir, m_name);
auto n = name();
// FIXME: This can fail to remove the metadata if the
// "DontUseModMetadata" setting is on, since there could
// be a name mismatch!
Metadata::remove(index_dir, n);
m_type = MOD_UNKNOWN;
return FS::deletePath(m_file.filePath());