Owner: Prevent use of uninitialized variable.

This commit is contained in:
Valentin Lorentz 2012-08-05 18:28:17 +02:00
parent ea17fe5c57
commit 22befe3d61

View File

@ -459,7 +459,7 @@ class Owner(callbacks.Plugin):
x = module.reload() x = module.reload()
try: try:
module = plugin.loadPluginModule(name) module = plugin.loadPluginModule(name)
if hasattr(module, 'reload'): if hasattr(module, 'reload') and 'x' in locals():
module.reload(x) module.reload(x)
for callback in callbacks: for callback in callbacks:
callback.die() callback.die()