mirror of
https://github.com/geode-sdk/geode.git
synced 2024-11-27 01:45:35 -05:00
make getLoadedMod and isModLoaded only return if the mod is also enabled
This commit is contained in:
parent
cb00c2105f
commit
3222097029
1 changed files with 2 additions and 2 deletions
|
@ -252,13 +252,13 @@ Mod* Loader::Impl::getInstalledMod(std::string const& id) const {
|
|||
}
|
||||
|
||||
bool Loader::Impl::isModLoaded(std::string const& id) const {
|
||||
return m_mods.count(id) && m_mods.at(id)->isLoaded();
|
||||
return m_mods.count(id) && m_mods.at(id)->isLoaded() && m_mods.at(id)->isEnabled();
|
||||
}
|
||||
|
||||
Mod* Loader::Impl::getLoadedMod(std::string const& id) const {
|
||||
if (m_mods.count(id)) {
|
||||
auto mod = m_mods.at(id);
|
||||
if (mod->isLoaded()) {
|
||||
if (mod->isLoaded() && mod->isEnabled()) {
|
||||
return mod;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue