From 94d8dc51359edd8d130a7645105ab3ddd51293c3 Mon Sep 17 00:00:00 2001 From: Alexandre <44178713+alexbelgium@users.noreply.github.com> Date: Thu, 28 Apr 2022 08:49:04 +0200 Subject: [PATCH] Streamline code --- addons_updater/rootfs/etc/cont-init.d/99-run.sh | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/addons_updater/rootfs/etc/cont-init.d/99-run.sh b/addons_updater/rootfs/etc/cont-init.d/99-run.sh index 66d6389fe..87a8b52ea 100644 --- a/addons_updater/rootfs/etc/cont-init.d/99-run.sh +++ b/addons_updater/rootfs/etc/cont-init.d/99-run.sh @@ -131,13 +131,14 @@ if [ -f /data/"$BASENAME"/"$f"/updater.json ]; then #If beta flag, select beta version if [ "${BETA}" = true ]; then LOGINFO="... $SLUG : beta is on" && if [ "$VERBOSE" = true ]; then bashio::log.info "$LOGINFO"; fi - # shellcheck disable=SC2086 - LASTVERSION=$(lastversion --pre "$UPSTREAM" $ARGUMENTS) || continue + ARGUMENTS="$ARGUMENTS --pre" else LOGINFO="... $SLUG : beta is off" && if [ "$VERBOSE" = true ]; then bashio::log.info "$LOGINFO"; fi - # shellcheck disable=SC2086 - LASTVERSION=$(lastversion "$UPSTREAM" $ARGUMENTS) || continue fi + + #Execute version search + # shellcheck disable=SC2086 + LASTVERSION=$(lastversion "$UPSTREAM" $ARGUMENTS) || continue fi