From d2d983f10a552952128002f053f440a928d6dba8 Mon Sep 17 00:00:00 2001 From: Doug Blank Date: Thu, 13 May 2010 13:02:52 +0000 Subject: [PATCH] Try to reload first; if fails, then not in path (addon), and try new import svn: r15403 --- src/gen/plug/_manager.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/gen/plug/_manager.py b/src/gen/plug/_manager.py index 7026a27f9..5705b881a 100644 --- a/src/gen/plug/_manager.py +++ b/src/gen/plug/_manager.py @@ -256,11 +256,11 @@ class BasePluginManager(object): """ Reloads modules that might not be in the path. """ - if pdata.mod_name in sys.modules: - del sys.modules[pdata.mod_name] try: reload(module) except: + if pdata.mod_name in sys.modules: + del sys.modules[pdata.mod_name] module = self.import_plugin(pdata) return module