diff --git a/inc/power.inc.sh b/inc/power.inc.sh index 0ec80e42..b6ba4ae2 100644 --- a/inc/power.inc.sh +++ b/inc/power.inc.sh @@ -1465,7 +1465,7 @@ POWERLOGGER_SERVICE(){ KYLE_WATT=`echo "scale=2; ${UPS_VOLTOUT}*${UPS_AMPSOUT}" | tr -d $'\r' | bc` - if [ "${UPS_AMPSOUT}" != "" ]; then + if [ "${KYLE_AMP}" != "" ]; then QRY="INSERT INTO power_data (sensorid, date, volt, amp, watt) VALUES ('${PW_POWERSENSOR_ID['KP-Power']}',CONVERT_TZ('${LogDataTime}', 'America/Chicago', 'UTC'),'${KYLE_VOLT}','${KYLE_AMP}','${KYLE_WATT}')" ${mysql_conn} -e "USE servermonitor; ${QRY}"