File tree Expand file tree Collapse file tree 1 file changed +3
-7
lines changed
custom_components/plugwise_usb Expand file tree Collapse file tree 1 file changed +3
-7
lines changed Original file line number Diff line number Diff line change 2020@callback
2121def plugwise_stick_entries (hass ):
2222 """Return existing connections for Plugwise USB-stick domain."""
23- sticks = []
24- for entry in hass .config_entries .async_entries (DOMAIN ):
25- sticks .append (entry .data .get (CONF_USB_PATH ))
26- return sticks
23+
24+ return [entry .data .get (CONF_USB_PATH ) for entry in hass .config_entries .async_entries (DOMAIN )]
2725
2826
2927async def validate_usb_connection (
@@ -114,9 +112,7 @@ async def async_step_manual_path(
114112 step_id = "manual_path" ,
115113 data_schema = vol .Schema (
116114 {
117- vol .Required (
118- CONF_USB_PATH , default = "/dev/ttyUSB0" or vol .UNDEFINED
119- ): str
115+ vol .Required (CONF_USB_PATH , default = "/dev/ttyUSB0" ): str
120116 }
121117 ),
122118 errors = errors ,
You can’t perform that action at this time.
0 commit comments