From 197388a9b2bbf762ef07e66f089b719ac6a1c0dc Mon Sep 17 00:00:00 2001 From: Paulus Schoutsen Date: Sun, 10 Apr 2016 17:35:10 -0700 Subject: [PATCH] Prevent device tracker error --- homeassistant/components/device_tracker/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/homeassistant/components/device_tracker/__init__.py b/homeassistant/components/device_tracker/__init__.py index 1866e972e28..beb9e4a7214 100644 --- a/homeassistant/components/device_tracker/__init__.py +++ b/homeassistant/components/device_tracker/__init__.py @@ -94,7 +94,7 @@ def setup(hass, config): yaml_path = hass.config.path(YAML_DEVICES) conf = config.get(DOMAIN, {}) - if isinstance(conf, list): + if isinstance(conf, list) and len(conf) > 0: conf = conf[0] consider_home = timedelta( seconds=util.convert(conf.get(CONF_CONSIDER_HOME), int,