summaryrefslogtreecommitdiff
path: root/cloudinit/stages.py
diff options
context:
space:
mode:
authorRémy Léone <rleone@online.net>2018-03-01 18:23:32 +0100
committerScott Moser <smoser@ubuntu.com>2018-03-02 12:53:26 -0500
commitffc6917aa0b97811c1e8503cd4cff9f11c15def1 (patch)
treebb2f58a42472a1d62cc9dfda544f7118a842b80a /cloudinit/stages.py
parent40e77380e036a24fafe91a63d0cdefada4312348 (diff)
downloadcloud-init-git-ffc6917aa0b97811c1e8503cd4cff9f11c15def1.tar.gz
Change some list creation and population to literal.
This will provide a small performance improvement and shorter code.
Diffstat (limited to 'cloudinit/stages.py')
-rw-r--r--cloudinit/stages.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/cloudinit/stages.py b/cloudinit/stages.py
index d0452688..bc4ebc85 100644
--- a/cloudinit/stages.py
+++ b/cloudinit/stages.py
@@ -132,8 +132,7 @@ class Init(object):
return initial_dirs
def purge_cache(self, rm_instance_lnk=False):
- rm_list = []
- rm_list.append(self.paths.boot_finished)
+ rm_list = [self.paths.boot_finished]
if rm_instance_lnk:
rm_list.append(self.paths.instance_link)
for f in rm_list: