From 85c0de550cbf3d6d6e4cae25b3c8519d32a1017b Mon Sep 17 00:00:00 2001 From: William Scanlon Date: Mon, 3 Dec 2018 05:34:22 -0500 Subject: [PATCH] Use capability of sensor if present to fix multisensor Wink devices (#18907) --- homeassistant/components/wink/__init__.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/homeassistant/components/wink/__init__.py b/homeassistant/components/wink/__init__.py index a94f8c3bdf2..c4cefa2c2d1 100644 --- a/homeassistant/components/wink/__init__.py +++ b/homeassistant/components/wink/__init__.py @@ -690,6 +690,10 @@ class WinkDevice(Entity): @property def unique_id(self): """Return the unique id of the Wink device.""" + if hasattr(self.wink, 'capability') and \ + self.wink.capability() is not None: + return "{}_{}".format(self.wink.object_id(), + self.wink.capability()) return self.wink.object_id() @property