From 646ff72a96d1bc8a39b70f5551598e7f5ea14975 Mon Sep 17 00:00:00 2001 From: tw93 Date: Sat, 28 Feb 2026 09:53:07 +0800 Subject: [PATCH] fix(clean): resolve unbound variable 'mount_points[@]' error in empty array case (#511) --- lib/clean/dev.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/clean/dev.sh b/lib/clean/dev.sh index edb8157..83234e2 100644 --- a/lib/clean/dev.sh +++ b/lib/clean/dev.sh @@ -390,7 +390,7 @@ clean_xcode_simulator_runtime_volumes() { local unused_count=0 for candidate in "${sorted_candidates[@]}"; do local status="UNUSED" - if _sim_runtime_is_path_in_use "$candidate" "${mount_points[@]}"; then + if [[ ${#mount_points[@]} -gt 0 ]] && _sim_runtime_is_path_in_use "$candidate" "${mount_points[@]}"; then status="IN_USE" in_use_count=$((in_use_count + 1)) else