diff --git a/scripts/upgrade b/scripts/upgrade index db37df7..4ed1b97 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -34,6 +34,15 @@ ynh_script_progression --message="Checking version..." upgrade_type=$(ynh_check_app_version_changed) +#================================================= +# FIX MISSING APP SETTING THAT BREAKS BACKUP +#================================================= +# If datapath doesn't exist, create it +if [ -z "$datapath" ]; then + datapath=/home/yunohost.app/$app + ynh_app_setting_set --app=$app --key=datapath --value=$datapath +fi + #================================================= # BACKUP BEFORE UPGRADE THEN ACTIVE TRAP #=================================================