Merge lp:~harlowja/cloud-init/fixer-up into lp:~cloud-init-dev/cloud-init/trunk

Proposed by Joshua Harlow
Status: Merged
Merged at revision: 1004
Proposed branch: lp:~harlowja/cloud-init/fixer-up
Merge into: lp:~cloud-init-dev/cloud-init/trunk
Diff against target: 21 lines (+2/-2)
1 file modified
cloudinit/sources/__init__.py (+2/-2)
To merge this branch: bzr merge lp:~harlowja/cloud-init/fixer-up
Reviewer Review Type Date Requested Status
cloud-init Commiters Pending
Review via email: mp+233126@code.launchpad.net

Description of the change

Fix logic statement and pep8 line offset

To post a comment you must log in.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'cloudinit/sources/__init__.py'
2--- cloudinit/sources/__init__.py 2014-08-26 18:50:11 +0000
3+++ cloudinit/sources/__init__.py 2014-09-02 21:18:41 +0000
4@@ -66,7 +66,7 @@
5 name = name[0:-3]
6
7 self.ds_cfg = util.get_cfg_by_path(self.sys_cfg,
8- ("datasource", name), {})
9+ ("datasource", name), {})
10 if not ud_proc:
11 self.ud_proc = ud.UserDataProcessor(self.paths)
12 else:
13@@ -166,7 +166,7 @@
14 defhost = "localhost"
15 domain = defdomain
16
17- if self.metadata or 'local-hostname' not in self.metadata:
18+ if not self.metadata or 'local-hostname' not in self.metadata:
19 # this is somewhat questionable really.
20 # the cloud datasource was asked for a hostname
21 # and didn't have one. raising error might be more appropriate