fixed 'on_startup() takes 0 positional arguments but 1 was given' (#17295)

pull/17361/head
Paul Annekov 2018-10-10 15:24:30 +03:00 committed by Paulus Schoutsen
parent 951d7154b8
commit 1d78393680
1 changed files with 1 additions and 1 deletions

View File

@ -106,7 +106,7 @@ class MiFloraSensor(Entity):
async def async_added_to_hass(self):
"""Set initial state."""
@callback
def on_startup():
def on_startup(_):
self.async_schedule_update_ha_state(True)
self.hass.bus.async_listen_once(EVENT_HOMEASSISTANT_START, on_startup)