Always add friendly name attribute to ZHA entities (#19141)

* Always add friendly name attribute

* Only change device_info name
This commit is contained in:
damarco authored and Paulus Schoutsen committed 2018-12-14 10:25:41 +01:00
1 parent afa48c54e9
commit 14d90b5484
1 file changed
+1 -1
@@ -100,6 +100,6 @@ class ZhaEntity(entity.Entity):
'identifiers': {(DOMAIN, ieee)},
'manufacturer': self._endpoint.manufacturer,
'model': self._endpoint.model,
'name': self._device_state_attributes['friendly_name'],
'name': self._device_state_attributes.get('friendly_name', ieee),
'via_hub': (DOMAIN, self.hass.data[DATA_ZHA][DATA_ZHA_BRIDGE_ID]),
}