From f17cb6e203fd8122d7795c02204fbbb3eab07773 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Fri, 12 Jan 2024 19:01:07 -0600 Subject: [PATCH] Update power.inc.sh --- inc/power.inc.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/inc/power.inc.sh b/inc/power.inc.sh index 19718ea0..beb06e0f 100644 --- a/inc/power.inc.sh +++ b/inc/power.inc.sh @@ -893,7 +893,8 @@ PDUCONTROL(){ [ ${portsel_power} -eq 1 ] && portsel_power_disp="${idsCL[Green]}ON" || portsel_power_disp="${idsCL[LightRed]}OFF" [ ${portsel_power} -eq 2 ] && portsel_change_power_disp="${idsCL[Green]}ON" || portsel_change_power_disp="${idsCL[LightRed]}OFF" - if [ "${PORT_SEL}" != "" ]; then + if [ "${PORTSEL}" != "" ]; then + PORT_DESC=(${PORT_DESC[@]}) # portdesc=$(snmpwalk -t 1 -r 0 -v 1 -c public ${PW_APCPDU_IP} .1.3.6.1.4.1.318.1.1.12.3.3.1.1.2.${PORT_SEL} -O vq 2> /dev/null | sed -e 's/"//g') echo -e "${idsCL[Yellow]}Port ${PORT_SEL}${idsCL[Default]}) ${idsCL[LightCyan]}${PORT_DESC[${PORT_SEL}]} ${idsCL[Default]}: ${portsel_power_disp}${idsCL[Default]}\n" fi