From 75557091efc61efef97de8a3e20eb001ecec719d Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Tue, 19 Oct 2021 15:43:23 -0400 Subject: [PATCH] Treat blank enclosure/bay as unset If someone does the obvious approach to blank something, treat that as equivalent. --- .../confluent/plugins/hardwaremanagement/enclosure.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py b/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py index 8d64e78b..933a852b 100644 --- a/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py +++ b/confluent_server/confluent/plugins/hardwaremanagement/enclosure.py @@ -26,6 +26,10 @@ def update(nodes, element, configmanager, inputdata): except KeyError: em = node eb = -1 + if not em: + em = node + if not eb: + eb = -1 try: for rsp in core.handle_path( '/nodes/{0}/_enclosure/reseat_bay'.format(em),