From dafd9a18a4b1573ff536e3db851e9e40a345c201 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Sun, 11 Apr 2021 12:19:07 +0300 Subject: custom references to "PluginDisable" module removed --- src/mir_app/src/newplugins.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'src/mir_app') diff --git a/src/mir_app/src/newplugins.cpp b/src/mir_app/src/newplugins.cpp index 12918f3426..9f91136a80 100644 --- a/src/mir_app/src/newplugins.cpp +++ b/src/mir_app/src/newplugins.cpp @@ -421,8 +421,14 @@ pluginEntry* OpenPlugin(wchar_t *tszFileName, wchar_t *dir, wchar_t *path) MIR_APP_DLL(void) SetPluginOnWhiteList(const char* szPluginName, bool bAllow) { - if (szPluginName != nullptr) - db_set_b(0, PLUGINDISABLELIST, CPluginName(szPluginName).c_str(), !bAllow); + if (szPluginName == nullptr) + return; + + CPluginName tmp(szPluginName); + if (bAllow) + db_unset(0, PLUGINDISABLELIST, tmp); + else + db_set_b(0, PLUGINDISABLELIST, tmp, 1); } // returns 1 if the plugin should be enabled within this profile, filename is always lower case -- cgit v1.2.3