mirror of
https://github.com/home-assistant/core.git
synced 2025-07-10 06:47:09 +00:00
Use DeviceInfo on esphome (#58396)
Co-authored-by: epenet <epenet@users.noreply.github.com>
This commit is contained in:
parent
4d7c55ff0e
commit
48c85fb839
@ -755,9 +755,9 @@ class EsphomeEntity(Entity, Generic[_InfoT, _StateT]):
|
|||||||
@property
|
@property
|
||||||
def device_info(self) -> DeviceInfo:
|
def device_info(self) -> DeviceInfo:
|
||||||
"""Return device registry information for this entity."""
|
"""Return device registry information for this entity."""
|
||||||
return {
|
return DeviceInfo(
|
||||||
"connections": {(dr.CONNECTION_NETWORK_MAC, self._device_info.mac_address)}
|
connections={(dr.CONNECTION_NETWORK_MAC, self._device_info.mac_address)}
|
||||||
}
|
)
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def name(self) -> str:
|
def name(self) -> str:
|
||||||
|
Loading…
x
Reference in New Issue
Block a user