summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Butcher <abutcher@redhat.com>2015-09-28 10:40:23 -0400
committerAndrew Butcher <abutcher@redhat.com>2015-09-28 10:51:23 -0400
commit9646ab206e5984ede420500343ccba5b81dd6187 (patch)
treed3b2230bc379013c1f5624c2936d87c55bb969ad
parent30f055111898dc1743f73bd0f8a018a40e58cf6d (diff)
downloadopenshift-9646ab206e5984ede420500343ccba5b81dd6187.tar.gz
openshift-9646ab206e5984ede420500343ccba5b81dd6187.tar.bz2
openshift-9646ab206e5984ede420500343ccba5b81dd6187.tar.xz
openshift-9646ab206e5984ede420500343ccba5b81dd6187.zip
Only continue to merge facts if both old and new values are type dict.
-rwxr-xr-xroles/openshift_facts/library/openshift_facts.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/roles/openshift_facts/library/openshift_facts.py b/roles/openshift_facts/library/openshift_facts.py
index 991b8da66..f708f9bac 100755
--- a/roles/openshift_facts/library/openshift_facts.py
+++ b/roles/openshift_facts/library/openshift_facts.py
@@ -644,7 +644,7 @@ def merge_facts(orig, new):
facts = dict()
for key, value in orig.iteritems():
if key in new:
- if isinstance(value, dict):
+ if isinstance(value, dict) and isinstance(new[key], dict):
facts[key] = merge_facts(value, new[key])
else:
facts[key] = copy.copy(new[key])