mirror of
https://github.com/home-assistant/core.git
synced 2025-07-21 12:17:07 +00:00
Change iOS sensor unique ID to use the device ID
This commit is contained in:
parent
919bb08d02
commit
b7141901f6
@ -56,7 +56,8 @@ class IOSSensor(Entity):
|
||||
@property
|
||||
def unique_id(self):
|
||||
"""Return the unique ID of this sensor."""
|
||||
return "sensor_ios_battery_{}_{}".format(self.type, self._device_name)
|
||||
device_id = self._device[ios.ATTR_DEVICE_ID]
|
||||
return "sensor_ios_battery_{}_{}".format(self.type, device_id)
|
||||
|
||||
@property
|
||||
def unit_of_measurement(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user