mirror of
https://github.com/home-assistant/core.git
synced 2025-12-24 21:06:19 +00:00
Update __init__.py
Updated to fix the following error when loading sensors:
"home-assistant/homeassistant/components/sensor/__init__.py", line 87, in setup
hass.track_time_change(update_sensor_states, seconds=range(0, 60, 3))
TypeError: track_time_change() got an unexpected keyword argument 'seconds'"
the named parameter was using seconds instead of second
This commit is contained in:
@@ -84,6 +84,6 @@ def setup(hass, config):
|
||||
discovery.listen(hass, DISCOVERY_PLATFORMS.keys(), sensor_discovered)
|
||||
|
||||
# Fire every 3 seconds
|
||||
hass.track_time_change(update_sensor_states, seconds=range(0, 60, 3))
|
||||
hass.track_time_change(update_sensor_states, second=range(0, 60, 3))
|
||||
|
||||
return True
|
||||
|
||||
Reference in New Issue
Block a user