Skip to content

Commit 84e9a8e

Browse files
committed
ensure we never use an OrderedDict
1 parent b65aed4 commit 84e9a8e

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

custom_components/pyscript/config_flow.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Config flow for pyscript."""
2+
import json
23
from typing import Any, Dict
34

45
import voluptuous as vol
@@ -32,6 +33,8 @@ async def async_step_user(self, user_input: Dict[str, Any] = None) -> Dict[str,
3233

3334
async def async_step_import(self, import_config: Dict[str, Any] = None) -> Dict[str, Any]:
3435
"""Import a config entry from configuration.yaml."""
36+
import_config = json.loads(json.dumps(import_config))
37+
3538
# Check if import config entry matches any existing config entries
3639
# so we can update it if necessary
3740
entries = self.hass.config_entries.async_entries(DOMAIN)

0 commit comments

Comments
 (0)