From 1d0c812e44ca42cc7b15f12a4d75eb3499c3bb59 Mon Sep 17 00:00:00 2001 From: Vladimir Eremin Date: Wed, 2 Jan 2019 17:24:47 +0000 Subject: [PATCH] GPIO Switch Fix restore_mode validator (#296) --- esphomeyaml/components/switch/gpio.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/esphomeyaml/components/switch/gpio.py b/esphomeyaml/components/switch/gpio.py index f0f3c3515c..b8b8efa021 100644 --- a/esphomeyaml/components/switch/gpio.py +++ b/esphomeyaml/components/switch/gpio.py @@ -23,7 +23,7 @@ PLATFORM_SCHEMA = cv.nameable(switch.SWITCH_PLATFORM_SCHEMA.extend({ cv.GenerateID(): cv.declare_variable_id(GPIOSwitch), cv.GenerateID(CONF_MAKE_ID): cv.declare_variable_id(MakeGPIOSwitch), vol.Required(CONF_PIN): pins.gpio_output_pin_schema, - vol.Optional(CONF_RESTORE_MODE): cv.one_of(RESTORE_MODES, upper=True, space='_'), + vol.Optional(CONF_RESTORE_MODE): cv.one_of(*RESTORE_MODES, upper=True, space='_'), }).extend(cv.COMPONENT_SCHEMA.schema))