pesor / TTGO-T-HIGrow

The extremely good plant sensor named LILYGO TTGO-T-HIGrow, is here integrated into Home Assistant, via MQTT messages, that can be Autodiscovered, via the belonging Python program. The program supports both DHT sensors, the new BME280 sensor and the external soil temperature sensor.
https://github.com/pesor/TTGO-T-HIGrow
MIT License
70 stars 36 forks source link

Fix off-by-one SSID array access #1

Closed linusnielsen closed 3 years ago

linusnielsen commented 3 years ago

When none of the SSID names work, the loop will read outside the list of SSID names because of an off-by-one loop condition. This is the fix.

pesor commented 3 years ago

@linusnielsen you are completely right, I forgot to take the zero into account. Thanks for pointing it out, and I have merged your solution.