summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/lib/Server/Plugins/SGenshi.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/lib/Server/Plugins/SGenshi.py b/src/lib/Server/Plugins/SGenshi.py
index 93dc15e7b..4f3490dac 100644
--- a/src/lib/Server/Plugins/SGenshi.py
+++ b/src/lib/Server/Plugins/SGenshi.py
@@ -9,6 +9,9 @@ logger = logging.getLogger('Bcfg2.Plugins.SGenshi')
class SGenshiTemplateFile(Bcfg2.Server.Plugins.TGenshi.TemplateFile):
def get_xml_value(self, metadata):
+ if not hasattr(self, 'template'):
+ logger.error("No parsed template information for %s" % (self.name))
+ raise Bcfg2.Server.Plugin.PluginExecutionError
stream = self.template.generate(metadata=metadata,).filter( \
Bcfg2.Server.Plugins.TGenshi.removecomment)
data = stream.render('xml')