Skip to content

Commit b227b12

Browse files
authored
Add MQTT retain flag handling to pyscript trigger and message handler
Updates the message handler in `mqtt.py` to include the `retain` flag in its processed arguments.
1 parent e18e455 commit b227b12

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

custom_components/pyscript/mqtt.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,7 @@ async def mqtt_message_handler(mqttmsg):
4545
"topic": mqttmsg.topic,
4646
"payload": mqttmsg.payload,
4747
"qos": mqttmsg.qos,
48+
"retain": mqttmsg.retain,
4849
}
4950

5051
try:

0 commit comments

Comments
 (0)