mirror of
https://github.com/home-assistant/core.git
synced 2025-07-19 19:27:45 +00:00
Fix harmony duplicate detection (#12729)
This commit is contained in:
parent
71cab65df6
commit
98fef81d19
@ -71,7 +71,7 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
|
|||||||
port)
|
port)
|
||||||
|
|
||||||
# Ignore hub name when checking if this hub is known - ip and port only
|
# Ignore hub name when checking if this hub is known - ip and port only
|
||||||
if host and host[1:] in (h.host for h in DEVICES):
|
if host[1:] in ((h.host, h.port) for h in DEVICES):
|
||||||
_LOGGER.debug("Discovered host already known: %s", host)
|
_LOGGER.debug("Discovered host already known: %s", host)
|
||||||
return
|
return
|
||||||
elif CONF_HOST in config:
|
elif CONF_HOST in config:
|
||||||
@ -139,7 +139,7 @@ class HarmonyRemote(remote.RemoteDevice):
|
|||||||
_LOGGER.debug("HarmonyRemote device init started for: %s", name)
|
_LOGGER.debug("HarmonyRemote device init started for: %s", name)
|
||||||
self._name = name
|
self._name = name
|
||||||
self.host = host
|
self.host = host
|
||||||
self._port = port
|
self.port = port
|
||||||
self._state = None
|
self._state = None
|
||||||
self._current_activity = None
|
self._current_activity = None
|
||||||
self._default_activity = activity
|
self._default_activity = activity
|
||||||
|
Loading…
x
Reference in New Issue
Block a user