mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-04 12:26:58 +03:00
[Backport release-10.x] match disabled mods on uninstall (#4567)
This commit is contained in:
commit
6d59334777
1 changed files with 7 additions and 1 deletions
|
|
@ -207,7 +207,13 @@ void ResourceFolderModel::installResourceWithFlameMetadata(QString path, ModPlat
|
|||
bool ResourceFolderModel::uninstallResource(const QString& file_name, bool preserve_metadata)
|
||||
{
|
||||
for (auto& resource : m_resources) {
|
||||
if (resource->fileinfo().fileName() == file_name) {
|
||||
auto resourceFileInfo = resource->fileinfo();
|
||||
auto resourceFileName = resource->fileinfo().fileName();
|
||||
if (!resource->enabled() && resourceFileName.endsWith(".disabled")) {
|
||||
resourceFileName.chop(9);
|
||||
}
|
||||
|
||||
if (resourceFileName == file_name) {
|
||||
auto res = resource->destroy(indexDir(), preserve_metadata, false);
|
||||
|
||||
update();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue