Merge lp:~ltrager/maas-images/fix_ensure_product_entry into lp:maas-images

Proposed by Lee Trager
Status: Merged
Merged at revision: 342
Proposed branch: lp:~ltrager/maas-images/fix_ensure_product_entry
Merge into: lp:maas-images
Diff against target: 11 lines (+1/-1)
1 file modified
meph2/util.py (+1/-1)
To merge this branch: bzr merge lp:~ltrager/maas-images/fix_ensure_product_entry
Reviewer Review Type Date Requested Status
Scott Moser (community) Approve
Review via email: mp+307906@code.launchpad.net

Commit message

Modify ensure_product_entry to check for the existance of 'products' in tree dict.

To post a comment you must log in.
Revision history for this message
Scott Moser (smoser) wrote :

fix commit message to < 74 char summary, blank line, details.
other than that good.

Revision history for this message
Scott Moser (smoser) :
review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'meph2/util.py'
2--- meph2/util.py 2016-09-30 19:48:50 +0000
3+++ meph2/util.py 2016-10-07 02:59:26 +0000
4@@ -297,7 +297,7 @@
5 # by products_prune(preserve_empty_products=True), but that argument
6 # is not available in trusty. products_condense and other things
7 # may expect a 'products' entry, so put an empty one there.
8- if not tree['products']:
9+ if 'products' not in tree:
10 tree['products'] = {}
11 return
12

Subscribers

People subscribed via source and target branches