Change array in loop bashism to satisfy shellcheck
[releng/builder.git] / jjb / opendaylight-infra-cleanup-stale-stacks.sh
index 77edc93af0896976d753c597127eb2f4204072a2..76140a131dcfdd5e614e28fc47f38ccd0d389b47 100644 (file)
@@ -36,7 +36,7 @@ done
 # delete them.
 for STACK_NAME in "${OS_STACKS[@]}"; do
     STACK_STATUS=$(openstack stack show -f json -c "stack_status" "$STACK_NAME" | jq -r '."stack_status"')
-    if [[ "${ACTIVE_BUILDS[@]}" =~ $STACK_NAME ]]; then
+    if [[ "${ACTIVE_BUILDS[*]}" =~ $STACK_NAME ]]; then
         # No need to delete stacks if there exists an active build for them
         continue
     else