mirror of
https://github.com/YunoHost/yunohost.git
synced 2024-09-03 20:06:10 +02:00
Improve robustness / idempotency(?) of new app catalog migration
This commit is contained in:
parent
67bb386c39
commit
b74c7c888c
1 changed files with 2 additions and 1 deletions
|
@ -44,7 +44,8 @@ class MyMigration(Migration):
|
|||
except Exception as e:
|
||||
logger.warning("Unable to parse the legacy conf %s (error : %s) ... migrating anyway" % (LEGACY_APPS_CATALOG_CONF, str(e)))
|
||||
|
||||
os.rename(LEGACY_APPS_CATALOG_CONF, LEGACY_APPS_CATALOG_CONF_BACKUP)
|
||||
if os.path.exists(LEGACY_APPS_CATALOG_CONF):
|
||||
os.rename(LEGACY_APPS_CATALOG_CONF, LEGACY_APPS_CATALOG_CONF_BACKUP)
|
||||
|
||||
_initialize_apps_catalog_system()
|
||||
_update_apps_catalog()
|
||||
|
|
Loading…
Add table
Reference in a new issue