summaryrefslogtreecommitdiff
path: root/cloudinit
diff options
context:
space:
mode:
Diffstat (limited to 'cloudinit')
-rw-r--r--cloudinit/stages.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/cloudinit/stages.py b/cloudinit/stages.py
index c2d78a78..05b59852 100644
--- a/cloudinit/stages.py
+++ b/cloudinit/stages.py
@@ -239,7 +239,7 @@ class Init(object):
previous_ds = util.load_file(ds_fn).strip()
except Exception:
pass
- if previous_ds is None:
+ if not previous_ds:
# TODO: ?? is this right
previous_ds = ds
util.write_file(ds_fn, "%s\n" % ds)
@@ -255,7 +255,7 @@ class Init(object):
previous_iid = util.load_file(p_iid_fn).strip()
except Exception:
pass
- if previous_iid is None:
+ if not previous_iid:
# TODO: ?? is this right
previous_iid = iid
util.write_file(c_iid_fn, "%s\n" % iid)