mirror of
https://github.com/munki/munki.git
synced 2026-04-22 20:48:36 -05:00
Fix for empty managed_installs or removals when printing available updates.
git-svn-id: http://munki.googlecode.com/svn/trunk@1240 a4e17f2e-e282-11dd-95e1-755cbddbdd66
This commit is contained in:
@@ -3011,7 +3011,7 @@ def check(client_id='', localmanifestpath=None):
|
||||
if installcount:
|
||||
munkicommon.display_info(
|
||||
'The following items will be installed or upgraded:')
|
||||
for item in installinfo['managed_installs']:
|
||||
for item in installinfo.get('managed_installs', []):
|
||||
if item.get('installer_item'):
|
||||
munkicommon.display_info(' + %s-%s' %
|
||||
(item.get('name',''),
|
||||
@@ -3028,7 +3028,7 @@ def check(client_id='', localmanifestpath=None):
|
||||
|
||||
if removalcount:
|
||||
munkicommon.display_info('The following items will be removed:')
|
||||
for item in installinfo['removals']:
|
||||
for item in installinfo.get('removals', []):
|
||||
if item.get('installed'):
|
||||
munkicommon.display_info(' - %s' % item.get('name'))
|
||||
if item.get('RestartAction') == 'RequireRestart' or \
|
||||
|
||||
Reference in New Issue
Block a user