1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/mopidy_ynh.git synced 2024-09-03 19:46:21 +02:00

Fix old upgrade

This commit is contained in:
Salamandar 2024-01-22 12:56:28 +01:00
parent fc003d63e0
commit bc4ca64801

View file

@ -18,6 +18,17 @@ ynh_script_progression --message="Ensuring downward compatibility..." --weight=1
ynh_secure_remove "$install_dir/env"
# Legacy settings
if [ -n "${mpd_port:-}" ]; then
if [ "$mpd_port" -eq 0 ]; then
mpd_ext=0
else
mpd_ext=1
fi
ynh_app_setting_set --app="$app" --key=mpd_ext --value="$mpd_ext"
ynh_app_setting_delete --app="$app" --key=mpd_port
fi
if [ -z "${mpd_state:-}" ]; then
mpd_state="${boolstr[mpd_ext]}"
ynh_app_setting_set --app="$app" --key=mpd_state --value="$mpd_state"