summaryrefslogtreecommitdiffstats
path: root/src/lib
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/Server/Plugins/Metadata.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/lib/Server/Plugins/Metadata.py b/src/lib/Server/Plugins/Metadata.py
index f4daf99b7..2ef9b1f59 100644
--- a/src/lib/Server/Plugins/Metadata.py
+++ b/src/lib/Server/Plugins/Metadata.py
@@ -137,9 +137,8 @@ class Metadata(Bcfg2.Server.Plugin.Plugin):
self.groups = {}
grouptmp = {}
self.categories = {}
- for group in xdata.findall('.//Group'):
- if group.getparent().tag == 'Group':
- continue
+ for group in xdata.xpath('//Groups/Group') \
+ + xdata.xpath('Group'):
grouptmp[group.get('name')] = tuple([[item.get('name') for item in group.findall(spec)]
for spec in ['./Bundle', './Group']])
grouptmp[group.get('name')][1].append(group.get('name'))