From 57c3245a64c8308e2184cb46f3f878ba99fd32bc Mon Sep 17 00:00:00 2001 From: ericgaspar Date: Sun, 21 Mar 2021 09:20:17 +0100 Subject: [PATCH] Update upgrade --- scripts/upgrade | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 64d2333..493011e 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -57,12 +57,11 @@ if [ -z "$max_file_size" ]; then ynh_app_setting_set --app=$app --key=max_file_size --value=$max_file_size fi -# Make app public if necessary -if [ $is_public -eq 1 ] -then - # Everyone can access the app. - # The "main" permission is automatically created before the install script. - ynh_permission_update --permission="main" --add="visitors" +# Cleaning legacy permissions +if ynh_legacy_permissions_exists; then + ynh_legacy_permissions_delete_all + + ynh_app_setting_delete --app=$app --key=is_public fi #=================================================