From 850308ffcf7a3a738bc74d0e547d8660342cf58c Mon Sep 17 00:00:00 2001 From: Martin Sivak Date: Fri, 29 Feb 2008 14:20:01 +0100 Subject: Fix behaviour when default flow does not exist and the auto mode is running without specified flow --- pyfirstaidkit/interpret.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pyfirstaidkit/interpret.py b/pyfirstaidkit/interpret.py index 0ff1aeb..79f2f21 100644 --- a/pyfirstaidkit/interpret.py +++ b/pyfirstaidkit/interpret.py @@ -96,8 +96,8 @@ class Tasker: oldlist = copy.copy(actlist) for plugin in oldlist: #If plugin does not contain the automated flow or if it ran correctly, remove it from list - if flow and not flow in pluginSystem.getplugin(plugin).getFlows(): - self._reporting.info("Plugin %s does not contain flow %s" % (plugin, flow,), origin = TASKER) + if (flow and not flow in pluginSystem.getplugin(plugin).getFlows()) or (not flow and not pluginSystem.getplugin(plugin).default_flow in pluginSystem.getplugin(plugin).getFlows()): + self._reporting.info("Plugin %s does not contain flow %s" % (plugin, flow or pluginSystem.getplugin(plugin).default_flow,), origin = TASKER) actlist.remove(plugin) elif pluginSystem.autorun(plugin, flow = flow): actlist.remove(plugin) -- cgit