mirror of
https://github.com/tomaae/homeassistant-mikrotik_router.git
synced 2025-06-28 19:50:06 +02:00
Code cleanup
This commit is contained in:
parent
ec1788ad3a
commit
d245bed440
3 changed files with 35 additions and 16 deletions
|
@ -383,7 +383,10 @@ class MikrotikControllerPortBinarySensor(MikrotikControllerBinarySensor):
|
|||
@property
|
||||
def unique_id(self) -> str:
|
||||
"""Return a unique id for this entity."""
|
||||
return f"{self._inst.lower()}-{self._sid_data['sid']}-{self._data['port-mac-address']}_{self._data['default-name']}"
|
||||
return (
|
||||
f"{self._inst.lower()}-{self._sid_data['sid']}-"
|
||||
f"{self._data['port-mac-address']}_{self._data['default-name']}"
|
||||
)
|
||||
|
||||
@property
|
||||
def is_on(self) -> bool:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue