fixing hook_handle for when result is never assigned, avoid reference without assignent
authorChristopher Allan Webber <cwebber@dustycloud.org>
Fri, 19 Apr 2013 19:58:22 +0000 (14:58 -0500)
committerChristopher Allan Webber <cwebber@dustycloud.org>
Fri, 19 Apr 2013 19:58:22 +0000 (14:58 -0500)
mediagoblin/tools/pluginapi.py

index 3ff16bcd627512eae6a3257e47f69529fb3dcff2..005862682822d506d0ba88f647cbf8019d4821fc 100644 (file)
@@ -368,6 +368,8 @@ def hook_handle(hook_name, *args, **kwargs):
 
     callables = PluginManager().get_hook_callables(hook_name)
 
+    result = None
+
     for callable in callables:
         result = callable(*args, **kwargs)