mirror of
https://github.com/andvikt/mega_hacs.git
synced 2025-12-12 09:34:28 +05:00
Compare commits
2 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
dc6bdfc8f4 | ||
|
|
e51b50797c |
@@ -60,7 +60,8 @@ class MegaD:
|
|||||||
):
|
):
|
||||||
"""Initialize."""
|
"""Initialize."""
|
||||||
if mqtt_inputs is None or mqtt_inputs == 'None' or mqtt_inputs is False:
|
if mqtt_inputs is None or mqtt_inputs == 'None' or mqtt_inputs is False:
|
||||||
self.http = hass.data[DOMAIN][CONF_HTTP]
|
self.http = hass.data.get(DOMAIN, {}).get(CONF_HTTP)
|
||||||
|
if not self.http is None:
|
||||||
self.http.allowed_hosts |= {host}
|
self.http.allowed_hosts |= {host}
|
||||||
else:
|
else:
|
||||||
self.http = None
|
self.http = None
|
||||||
|
|||||||
Reference in New Issue
Block a user