summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Sivak <msivak@redhat.com>2012-10-08 17:59:50 +0200
committerMartin Sivak <msivak@redhat.com>2012-10-08 17:59:50 +0200
commita04a4a776c3ce666cea88fd9332186330ecf97b1 (patch)
treeaaaef75027c5fe3953d421e8e781671e64ae0d98
parent799e577c0adf2dc02970594b73969b02daf04f72 (diff)
downloadfirstboot2-a04a4a776c3ce666cea88fd9332186330ecf97b1.tar.gz
firstboot2-a04a4a776c3ce666cea88fd9332186330ecf97b1.tar.xz
firstboot2-a04a4a776c3ce666cea88fd9332186330ecf97b1.zip
Fix firstboot category&spoke collector
-rw-r--r--firstboot/gui/hubs/firstboot.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/firstboot/gui/hubs/firstboot.py b/firstboot/gui/hubs/firstboot.py
index 170a98f..6a12029 100644
--- a/firstboot/gui/hubs/firstboot.py
+++ b/firstboot/gui/hubs/firstboot.py
@@ -16,9 +16,8 @@ def collect_spokes(mask_paths):
spokes = []
for mask, path in mask_paths:
spokes.extend(collect(mask, path,
- lambda obj: hasattr(obj, "category")
- and obj.category != None))
-
+ lambda obj: hasattr(obj, "firstboot")))
+
return spokes
@@ -40,7 +39,8 @@ class FirstbootHub(SummaryHub):
if hasattr(spoke, "firstboot") and spoke.firstboot()]
for spoke in spokes:
- ret[spoke.category] = spoke
+ ret.setdefault(spoke.category, [])
+ ret[spoke.category].append(spoke)
return ret