Skip to content
Snippets Groups Projects
Commit cb851783 authored by Fabian Affolter's avatar Fabian Affolter Committed by GitHub
Browse files

Do not call update() in constructor. (#8837)

parent f41ef5d7
No related branches found
No related tags found
No related merge requests found
......@@ -75,7 +75,7 @@ def setup_platform(hass, config, add_devices, discovery_info=None):
resource['arg'] = ''
dev.append(SystemMonitorSensor(resource[CONF_TYPE], resource['arg']))
add_devices(dev)
add_devices(dev, True)
class SystemMonitorSensor(Entity):
......@@ -88,7 +88,6 @@ class SystemMonitorSensor(Entity):
self.type = sensor_type
self._state = None
self._unit_of_measurement = SENSOR_TYPES[sensor_type][1]
self.update()
@property
def name(self):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment