summaryrefslogtreecommitdiffstats
path: root/cobbler/utils.py
diff options
context:
space:
mode:
authorMichael DeHaan <mdehaan@redhat.com>2007-10-10 18:32:18 -0400
committerMichael DeHaan <mdehaan@redhat.com>2007-10-10 18:32:18 -0400
commit08bd3ff156fe7bd20ce83529190c3a1793ba3c0a (patch)
tree65cd3540e0a9b4d055d56686140f5175348e72ff /cobbler/utils.py
parent549019bd5e129a3ff3699cd54a4a97c3545afb92 (diff)
downloadthird_party-cobbler-08bd3ff156fe7bd20ce83529190c3a1793ba3c0a.tar.gz
third_party-cobbler-08bd3ff156fe7bd20ce83529190c3a1793ba3c0a.tar.xz
third_party-cobbler-08bd3ff156fe7bd20ce83529190c3a1793ba3c0a.zip
Remove some dead code and update a few FIXMEs that no longer apply.
Diffstat (limited to 'cobbler/utils.py')
-rw-r--r--cobbler/utils.py16
1 files changed, 5 insertions, 11 deletions
diff --git a/cobbler/utils.py b/cobbler/utils.py
index 48e79d8..f8b2193 100644
--- a/cobbler/utils.py
+++ b/cobbler/utils.py
@@ -315,13 +315,17 @@ def blender(remove_hashes, root_obj):
def flatten(data):
# convert certain nested hashes to strings.
- # FIXME: this function should be made more generic
+ # this is only really done for the ones koan needs as strings
+ # this should not be done for everything
if data.has_key("kernel_options"):
data["kernel_options"] = hash_to_string(data["kernel_options"])
+ # FIXME: why do we flatten this?
if data.has_key("ks_meta"):
data["ks_meta"] = hash_to_string(data["ks_meta"])
+ # FIXME: why do we flatten this?
if data.has_key("repos") and type(data["repos"]) == list:
data["repos"] = " ".join(data["repos"])
+ # FIXME: why do we flatten this?
if data.has_key("rpm_list") and type(data["rpm_list"]) == list:
data["rpm_list"] = " ".join(data["rpm_list"])
@@ -356,16 +360,6 @@ def __consolidate(node,results):
data_item = node_data_copy[field]
if results.has_key(field):
- # FIXME: remove, we're doing this higher up
- # for subobjects (child objects), a value of <<inherit>>
- # means defer up the stack, and by definition usage of the API
- # must ensure the value is valid somewhere up the stack. So, remove
- # any magic values of <<inherit>> prior to blending.
- #if data_item == '<<inherit>>':
- # # don't load into results hash, the parent will have the
- # # data we need.
- # continue
-
# now merge data types seperately depending on whether they are hash, list,
# or scalar.
if type(data_item) == dict: