mirror of
https://github.com/home-assistant/core.git
synced 2025-08-04 13:15:18 +02:00
Fix Coronavirus
This commit is contained in:
@@ -38,6 +38,8 @@ class CoronavirusSensor(CoordinatorEntity, SensorEntity):
|
|||||||
else:
|
else:
|
||||||
self.name = f"{coordinator.data[country].country} Coronavirus {info_type}"
|
self.name = f"{coordinator.data[country].country} Coronavirus {info_type}"
|
||||||
self.unique_id = f"{country}-{info_type}"
|
self.unique_id = f"{country}-{info_type}"
|
||||||
|
self.country = country
|
||||||
|
self.info_type = info_type
|
||||||
|
|
||||||
self._icon = SENSORS[self.info_type]
|
self._icon = SENSORS[self.info_type]
|
||||||
self._unit_of_measurement = "people"
|
self._unit_of_measurement = "people"
|
||||||
|
Reference in New Issue
Block a user