From 4245ac9161f3a9353abd53639549ded27d88471b Mon Sep 17 00:00:00 2001 From: github-actions <41898282+github-actions[bot]@users.noreply.github.com> Date: Tue, 24 Jun 2025 15:56:45 +0000 Subject: [PATCH] GitHub bot: fix linting issues (nobuild) --- .../rootfs/etc/cont-init.d/00-folders.sh | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/resiliosync/rootfs/etc/cont-init.d/00-folders.sh b/resiliosync/rootfs/etc/cont-init.d/00-folders.sh index 1398a0b42..dac26300a 100755 --- a/resiliosync/rootfs/etc/cont-init.d/00-folders.sh +++ b/resiliosync/rootfs/etc/cont-init.d/00-folders.sh @@ -78,13 +78,13 @@ fi # Add directories to dir_whitelist if missing DIRS_TO_ADD=("/backup" "/media" "/share" "/addons") for CONFIG_FILE in "$(bashio::config 'config_location')/sync.conf" "/defaults/sync.conf"; do - if [ -f "$CONFIG_FILE" ]; then - echo "Checking dir_whitelist in $CONFIG_FILE" - for DIR in "${DIRS_TO_ADD[@]}"; do - if ! jq -e ".webui.dir_whitelist | index(\"$DIR\")" "$CONFIG_FILE" > /dev/null; then - echo "Adding $DIR to dir_whitelist" - jq ".webui.dir_whitelist += [\"$DIR\"]" "$CONFIG_FILE" | sponge "$CONFIG_FILE" - fi - done - fi + if [ -f "$CONFIG_FILE" ]; then + echo "Checking dir_whitelist in $CONFIG_FILE" + for DIR in "${DIRS_TO_ADD[@]}"; do + if ! jq -e ".webui.dir_whitelist | index(\"$DIR\")" "$CONFIG_FILE" >/dev/null; then + echo "Adding $DIR to dir_whitelist" + jq ".webui.dir_whitelist += [\"$DIR\"]" "$CONFIG_FILE" | sponge "$CONFIG_FILE" + fi + done + fi done