File tree Expand file tree Collapse file tree
custom_components/bms_ble Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -213,7 +213,7 @@ async def async_step_init(
213213 )
214214 if not bms_class :
215215 return self .async_abort (reason = "not_supported" )
216- if not bms_class .accept_secret and not self . show_advanced_options :
216+ if not bms_class .accept_secret :
217217 LOGGER .debug ("No options for %s" , bms_class .bms_id ())
218218 return self .async_abort (
219219 reason = "device_has_no_options" ,
@@ -226,16 +226,14 @@ async def async_step_init(
226226 type = TextSelectorType .PASSWORD ,
227227 read_only = not bms_class .accept_secret ,
228228 )
229- )
230- }
231-
232- if self .show_advanced_options :
233- schema_dict [vol .Optional (CONF_ADVANCED_OPTIONS )] = section (
229+ ),
230+ vol .Optional (CONF_ADVANCED_OPTIONS ): section (
234231 vol .Schema (
235232 {vol .Optional (CONF_KEEP_ALIVE , default = True ): BooleanSelector ()}
236233 ),
237234 {"collapsed" : True },
238- )
235+ ),
236+ }
239237
240238 return self .async_show_form (
241239 step_id = "init" ,
You can’t perform that action at this time.
0 commit comments