1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-12-01 23:12:49 +02:00

Fix crash on attempt to install mod not present in mod repository

This commit is contained in:
Ivan Savenko
2024-12-15 19:37:25 +00:00
parent 88bf46f57b
commit d42ae2995b
2 changed files with 4 additions and 1 deletions

View File

@@ -120,6 +120,9 @@ bool ModStateController::disableMod(QString modname)
bool ModStateController::canInstallMod(QString modname)
{
if (!modList->isModExists(modname))
return true; // for installation of unknown mods, e.g. via "Install from file" option
auto mod = modList->getMod(modname);
if(mod.isSubmod())