diff --git a/scripts/upgrade b/scripts/upgrade index a075222..eb0b5ac 100644 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -12,7 +12,7 @@ fi sudo yunohost backup create --ignore-hooks --apps $app --name $app-before-upgrade --quiet EXIT_PROPERLY () { - trap '' EXIT + trap '' ERR set +eu sudo yunohost backup restore --ignore-hooks $app-before-upgrade --apps $app --force --quiet # Restore the backup if upgrade failed ynh_die "Upgrade failed. The app was restored to the way it was before the failed upgrade."