Skip to content

Commit 757e958

Browse files
committed
Remove unnecessary "disabled" check in plugin unload
1 parent efbbe57 commit 757e958

1 file changed

Lines changed: 0 additions & 6 deletions

File tree

cloudbot/plugin.py

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -293,12 +293,6 @@ def unload_plugin(self, path):
293293
"""
294294
path = Path(path)
295295
file_path = path.resolve()
296-
plugin_path = file_path.relative_to(self.bot.base_dir)
297-
298-
title = '.'.join(plugin_path.parts[1:]).rsplit('.', 1)[0]
299-
if "disabled_plugins" in self.bot.config and title in self.bot.config['disabled_plugins']:
300-
# this plugin hasn't been loaded, so no need to unload it
301-
return False
302296

303297
# make sure this plugin is actually loaded
304298
if str(file_path) not in self.plugins:

0 commit comments

Comments
 (0)