Skip to content

Commit cff9b1b

Browse files
tsvipvizeli
authored andcommitted
Fix waze_travel_time component startup (home-assistant#16465)
* Fix waze_travel_time component startup * Remove @Throttle decorator as per pvizelli's request * Make the linting gods happy again
1 parent ce06229 commit cff9b1b

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

homeassistant/components/sensor/waze_travel_time.py

+2-3
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@
1616
import homeassistant.helpers.config_validation as cv
1717
from homeassistant.helpers import location
1818
from homeassistant.helpers.entity import Entity
19-
from homeassistant.util import Throttle
2019

2120
REQUIREMENTS = ['WazeRouteCalculator==0.6']
2221

@@ -71,7 +70,8 @@ def setup_platform(hass, config, add_entities, discovery_info=None):
7170
add_entities([sensor])
7271

7372
# Wait until start event is sent to load this component.
74-
hass.bus.listen_once(EVENT_HOMEASSISTANT_START, sensor.update)
73+
hass.bus.listen_once(
74+
EVENT_HOMEASSISTANT_START, lambda _: sensor.update())
7575

7676

7777
def _get_location_from_attributes(state):
@@ -182,7 +182,6 @@ def _resolve_zone(self, friendly_name):
182182

183183
return friendly_name
184184

185-
@Throttle(SCAN_INTERVAL)
186185
def update(self):
187186
"""Fetch new state data for the sensor."""
188187
import WazeRouteCalculator

0 commit comments

Comments
 (0)