diff --git a/aircon.sh b/aircon.sh index ae0f82f..4116dc7 100755 --- a/aircon.sh +++ b/aircon.sh @@ -379,6 +379,11 @@ function find_nearby_zones() { # zone_idx filter1 filter2 ... filter is: o if [[ $conditions == *noaction* && ${zaction[$zi]} != "n/a" ]]; then ok=0 fi + if [[ $conditions == *open* && $constant == ${zname[$zi]} ]]; then + # the constant zone never counts as an adjacent 'open' zone, because + # if we were to close it, it would just get opened again. + ok=0 + fi if [[ $ok -eq 1 ]]; then nearbyzones="$nearbyzones $thisone" fi