Merge pull request #551 from flahemade/stretch-unstable

Fix potential key error when retrieving install_time
This commit is contained in:
Alexandre Aubin 2018-10-24 19:25:29 +02:00 committed by GitHub
commit 5d8710d98c
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -346,7 +346,8 @@ def app_info(app, show_status=False, raw=False):
ret['settings'] = _get_app_settings(app) ret['settings'] = _get_app_settings(app)
# Determine upgradability # Determine upgradability
local_update_time = ret['settings'].get('update_time', ret['settings']['install_time']) # In case there is neither update_time nor install_time, we assume the app can/has to be upgraded
local_update_time = ret['settings'].get('update_time', ret['settings'].get('install_time', 0))
if 'lastUpdate' not in ret or 'git' not in ret: if 'lastUpdate' not in ret or 'git' not in ret:
upgradable = "url_required" upgradable = "url_required"