From 0ed72434b4e99af3d872683fa0959d2b8af1411c Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Sun, 20 Aug 2023 13:00:47 -0500 Subject: [PATCH] Update powerwall.sh --- powerwall.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/powerwall.sh b/powerwall.sh index f5bbd16c..fe10e5b5 100755 --- a/powerwall.sh +++ b/powerwall.sh @@ -134,7 +134,7 @@ AVERAGETEMP(){ daysback=${2} sensorid=${1} logsfound=0; - if [ "${PW_SENSOR_TYPE[${1}]}" == "esxi" ]; then + if [ "${PW_SENSOR_TYPE[${sensorid}]}" == "esxi" ]; then entityid=($(${mysql_conn} -e "SELECT id FROM servermonitor.entities WHERE BINARY name='${3}' AND sensorid='${sensorid}'")) entityid=${entityid[1]} # echo "HERE: ${3} - ${entityid}"