From 9acbcc805f206dbbab0dde03d7666f6505e79e7b Mon Sep 17 00:00:00 2001 From: Erik Date: Wed, 26 Sep 2018 20:35:39 +0200 Subject: [PATCH] Fix logic for forced light discovery --- sonoff/xdrv_12_home_assistant.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sonoff/xdrv_12_home_assistant.ino b/sonoff/xdrv_12_home_assistant.ino index b085947ae..c4e5d833b 100644 --- a/sonoff/xdrv_12_home_assistant.ino +++ b/sonoff/xdrv_12_home_assistant.ino @@ -76,7 +76,7 @@ void HAssDiscoverRelay() for (int i = 1; i <= MAX_RELAYS; i++) { is_light = ((i == devices_present) && (light_type)); - is_topic_light = Settings.flag.hass_light; + is_topic_light = Settings.flag.hass_light || is_light; mqtt_data[0] = '\0'; // Clear retained message