WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content
This repository was archived by the owner on Nov 19, 2021. It is now read-only.

Commit 3f3fd68

Browse files
committed
Add unique_id to sensors
Makes them show up in the integrations and makes them editable. Fixes #3 Fixes #4
1 parent 056d9a4 commit 3f3fd68

File tree

1 file changed

+4
-0
lines changed
  • custom_components/coronavirus_hessen

1 file changed

+4
-0
lines changed

custom_components/coronavirus_hessen/sensor.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@ def available(self):
4040
def name(self):
4141
return self._name
4242

43+
@property
44+
def unique_id(self):
45+
return self._name
46+
4347
@property
4448
def icon(self):
4549
return "mdi:biohazard"

0 commit comments

Comments
 (0)