From 6799eda120594327e5414cb405eeda9ac1a1c25e Mon Sep 17 00:00:00 2001 From: springstan Date: Wed, 4 Dec 2019 17:26:41 +0100 Subject: [PATCH] Move imports to top for canary --- homeassistant/components/canary/sensor.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/homeassistant/components/canary/sensor.py b/homeassistant/components/canary/sensor.py index 6bb01c9d114804..67654c99f3eb83 100644 --- a/homeassistant/components/canary/sensor.py +++ b/homeassistant/components/canary/sensor.py @@ -1,4 +1,5 @@ """Support for Canary sensors.""" +from canary.api import SensorType from homeassistant.const import TEMP_CELSIUS from homeassistant.helpers.entity import Entity @@ -103,8 +104,6 @@ def update(self): """Get the latest state of the sensor.""" self._data.update() - from canary.api import SensorType - canary_sensor_type = None if self._sensor_type[0] == "air_quality": canary_sensor_type = SensorType.AIR_QUALITY