[Dicson] remove plugin entry in global config when removing the plugin. Fixes #5918
This commit is contained in:
parent
0899ab13db
commit
90d1ee3176
1 changed files with 5 additions and 0 deletions
|
@ -117,6 +117,9 @@ class PluginManager(object):
|
|||
def _create_plugin_entry_in_global_config(self, plugin):
|
||||
gajim.config.add_per('plugins', plugin.short_name)
|
||||
|
||||
def _remove_plugin_entry_in_global_config(self, plugin):
|
||||
gajim.config.del_per('plugins', plugin.short_name)
|
||||
|
||||
@log_calls('PluginManager')
|
||||
def add_plugin(self, plugin_class):
|
||||
'''
|
||||
|
@ -519,6 +522,8 @@ class PluginManager(object):
|
|||
self.deactivate_plugin(plugin)
|
||||
rmtree(plugin.__path__, False, on_error)
|
||||
self.plugins.remove(plugin)
|
||||
if self._plugin_has_entry_in_global_config(plugin):
|
||||
self._remove_plugin_entry_in_global_config(plugin)
|
||||
|
||||
def get_plugin_by_path(self, plugin_dir):
|
||||
for plugin in self.plugins:
|
||||
|
|
Loading…
Add table
Reference in a new issue