mirror of
https://github.com/vcmi/vcmi.git
synced 2024-12-14 10:12:59 +02:00
Fix uncaught exception if newly updated mod has removed a submod
This commit is contained in:
parent
4180ea9523
commit
8a0d327ac2
@ -287,7 +287,7 @@ void ModsPresetState::eraseModSetting(const TModID & modName, const TModID & set
|
||||
{
|
||||
const std::string & currentPresetName = modConfig["activePreset"].String();
|
||||
JsonNode & currentPreset = modConfig["presets"][currentPresetName];
|
||||
currentPreset["settings"][modName].Struct().erase(modName);
|
||||
currentPreset["settings"][modName].Struct().erase(settingName);
|
||||
}
|
||||
|
||||
std::vector<TModID> ModsPresetState::getActiveMods() const
|
||||
|
Loading…
Reference in New Issue
Block a user