Skip to content

Commit

Permalink
Fixed state value bug
Browse files Browse the repository at this point in the history
Also a missed string format statement
  • Loading branch information
FlyingDiver committed May 29, 2022
1 parent 128b035 commit 7460c11
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion MQTT Shims.indigoPlugin/Contents/Info.plist
Expand Up @@ -3,7 +3,7 @@
<plist version="1.0">
<dict>
<key>PluginVersion</key>
<string>2022.0.1</string>
<string>2022.0.2</string>
<key>ServerApiVersion</key>
<string>3.0</string>
<key>IwsApiVersion</key>
Expand Down
4 changes: 2 additions & 2 deletions MQTT Shims.indigoPlugin/Contents/Server Plugin/plugin.py
Expand Up @@ -180,7 +180,7 @@ def convert_color_temp_export(device, color_temp):
# Convert a color space dict from the external device-specific value to Indigo space

def convert_color_space_import(self, device, color_dict):
self.logger.debug(u"{}: convert_color_space_import input: {}".format(device.name, color_dict))
self.logger.debug(f"{device.name}: convert_color_space_import input: {color_dict}")
space = device.pluginProps.get("color_space", "Indigo")
if space == "Indigo":
return color_dict
Expand Down Expand Up @@ -381,7 +381,7 @@ def update(self, device, topic_parts, payload):
device.updateStatesOnServer(states_list)

# Device type specific processing. No entry for ShimGeneric, it's all handled above
if not state_value:
if state_value is None:
return

if device.deviceTypeId in ["shimRelay", "shimOnOffSensor"]:
Expand Down

0 comments on commit 7460c11

Please sign in to comment.