From 91bf10cf0e2961e5e2ccb3ee45166e83d7a08417 Mon Sep 17 00:00:00 2001 From: tituspijean Date: Sun, 30 Apr 2023 19:06:05 +0200 Subject: [PATCH] Fix downward compatibility --- scripts/upgrade | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scripts/upgrade b/scripts/upgrade index 178a811..db91abb 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -24,19 +24,19 @@ upgrade_type=$(ynh_check_app_version_changed) ynh_script_progression --message="Ensuring downward compatibility..." --weight=1 # If fpm_footprint doesn't exist, create it -if [ -z "$fpm_footprint" ]; then +if [ -z "${fpm_footprint:-}" ]; then fpm_footprint=medium ynh_app_setting_set --app=$app --key=fpm_footprint --value=$fpm_footprint fi # If fpm_usage doesn't exist, create it -if [ -z "$fpm_usage" ]; then +if [ -z "${fpm_usage:-}" ]; then fpm_usage=medium ynh_app_setting_set --app=$app --key=fpm_usage --value=$fpm_usage fi # If with_sftp or password don't exist, create them -if [ -z "$with_sftp" ] || [ -z "$password" ]; then +if [ -z "${with_sftp:-}" ] || [ -z "${password:-}" ]; then ynh_app_setting_set --app=$app --key=with_sftp --value="false" ynh_app_setting_set --app=$app --key=password --value=$(ynh_string_random) fi