From 0f3901481214302175e50c9055e862a0ad81c0e6 Mon Sep 17 00:00:00 2001 From: OniriCorpe Date: Mon, 26 Feb 2024 02:19:48 +0100 Subject: [PATCH] fix upgrade, create 'default_matrix_server' if needed --- scripts/upgrade | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/scripts/upgrade b/scripts/upgrade index af4fa76..738de18 100755 --- a/scripts/upgrade +++ b/scripts/upgrade @@ -11,6 +11,12 @@ source /usr/share/yunohost/helpers upgrade_type=$(ynh_check_app_version_changed) +# if we update from a version prior to the config panel, create new setting +if [ -z "${default_matrix_server:-}" ]; then + default_matrix_server="matrix.org" + ynh_app_setting_set --app="$app" --key=default_matrix_server --value="$default_matrix_server" +fi + #================================================= # "REBUILD" THE APP (DEPLOY NEW SOURCES, RERUN NPM BUILD...) #=================================================