Merge pull request #3908 from emontnemery/fix_hass_forced_light

Fix logic for forced light discovery
This commit is contained in:
Theo Arends 2018-09-26 20:54:52 +02:00 committed by GitHub
commit 0eac385b04
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -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