From 8360ab265cfa34de4513218aa8c7e77da239fe3d Mon Sep 17 00:00:00 2001 From: Stefan Jonasson Date: Sun, 13 Sep 2015 20:34:45 +0200 Subject: [PATCH] Not used to pylint and flake8 ... --- homeassistant/components/automation/numeric_state.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/homeassistant/components/automation/numeric_state.py b/homeassistant/components/automation/numeric_state.py index c3f94695216..79312bc9e58 100644 --- a/homeassistant/components/automation/numeric_state.py +++ b/homeassistant/components/automation/numeric_state.py @@ -33,7 +33,7 @@ def register(hass, config, action): CONF_BELOW, CONF_ABOVE) return False - def numeric_in_range(value, range_start, range_end): + def _in_range(value, range_start, range_end): """ Checks if value is inside the range :param value: :param range_start: @@ -58,9 +58,8 @@ def register(hass, config, action): """ Listens for state changes and calls action. """ # Fire action if we go from outside range into range - if numeric_in_range(to_s.state, above, below) and \ - (from_s is None or \ - not numeric_in_range(from_s.state, above, below)): + if _in_range(to_s.state, above, below) and \ + (from_s is None or not _in_range(from_s.state, above, below)): action() track_state_change(