[fix] Allow old custom applications compatibility

This commit is contained in:
kload 2015-05-05 20:24:58 +02:00
parent 141f2ae8f5
commit b2ffe65da8
2 changed files with 2 additions and 2 deletions

View file

@ -311,7 +311,7 @@ def app_upgrade(auth, app=[], url=None, file=None):
manifest = _extract_app_from_file(file)
elif url:
manifest = _fetch_app_from_git(url)
elif 'lastUpdate' not in new_app_dict or 'git' not in new_app_dict:
elif new_app_dict is None or 'lastUpdate' not in new_app_dict or 'git' not in new_app_dict:
msignals.display(m18n.n('custom_app_url_required', app_id), 'warning')
continue
elif (new_app_dict['lastUpdate'] > current_app_dict['lastUpdate']) \

View file

@ -380,7 +380,7 @@ def tools_update(ignore_apps=False, ignore_packages=False):
new_app_dict = app_info(original_app_id, raw=True)
# Custom app
if 'lastUpdate' not in new_app_dict or 'git' not in new_app_dict:
if new_app_dict is None or 'lastUpdate' not in new_app_dict or 'git' not in new_app_dict:
continue
if (new_app_dict['lastUpdate'] > current_app_dict['lastUpdate']) \