mirror of
https://github.com/home-assistant/core.git
synced 2025-07-30 02:38:10 +02:00
Ensure MQTT subscriptions can be made when the broker is disconnected (#132270)
This commit is contained in:
@ -227,7 +227,7 @@ def async_subscribe_internal(
|
||||
translation_placeholders={"topic": topic},
|
||||
) from exc
|
||||
client = mqtt_data.client
|
||||
if not client.connected and not mqtt_config_entry_enabled(hass):
|
||||
if not mqtt_config_entry_enabled(hass):
|
||||
raise HomeAssistantError(
|
||||
f"Cannot subscribe to topic '{topic}', MQTT is not enabled",
|
||||
translation_key="mqtt_not_setup_cannot_subscribe",
|
||||
|
Reference in New Issue
Block a user