diff --git a/homeassistant/components/config/__init__.py b/homeassistant/components/config/__init__.py index d7a1e641c67..efabd03b586 100644 --- a/homeassistant/components/config/__init__.py +++ b/homeassistant/components/config/__init__.py @@ -1,13 +1,13 @@ """Component to configure Home Assistant via an API.""" import asyncio +import importlib import os import voluptuous as vol from homeassistant.core import callback from homeassistant.const import EVENT_COMPONENT_LOADED, CONF_ID -from homeassistant.setup import ( - async_prepare_setup_platform, ATTR_COMPONENT) +from homeassistant.setup import ATTR_COMPONENT from homeassistant.components.http import HomeAssistantView from homeassistant.util.yaml import load_yaml, dump @@ -36,8 +36,7 @@ async def async_setup(hass, config): async def setup_panel(panel_name): """Set up a panel.""" - panel = await async_prepare_setup_platform( - hass, config, DOMAIN, panel_name) + panel = importlib.import_module('.{}'.format(panel_name), __name__) if not panel: return diff --git a/homeassistant/components/config/area_registry.py b/homeassistant/components/config/area_registry.py index 7f1bb938228..06fc3eae34d 100644 --- a/homeassistant/components/config/area_registry.py +++ b/homeassistant/components/config/area_registry.py @@ -8,8 +8,6 @@ from homeassistant.core import callback from homeassistant.helpers.area_registry import async_get_registry -DEPENDENCIES = ['websocket_api'] - WS_TYPE_LIST = 'config/area_registry/list' SCHEMA_WS_LIST = websocket_api.BASE_COMMAND_MESSAGE_SCHEMA.extend({ vol.Required('type'): WS_TYPE_LIST, diff --git a/homeassistant/components/config/device_registry.py b/homeassistant/components/config/device_registry.py index 9554f6aeee6..d9e55bbe67e 100644 --- a/homeassistant/components/config/device_registry.py +++ b/homeassistant/components/config/device_registry.py @@ -7,8 +7,6 @@ from homeassistant.components.websocket_api.decorators import ( from homeassistant.core import callback from homeassistant.helpers.device_registry import async_get_registry -DEPENDENCIES = ['websocket_api'] - WS_TYPE_LIST = 'config/device_registry/list' SCHEMA_WS_LIST = websocket_api.BASE_COMMAND_MESSAGE_SCHEMA.extend({ vol.Required('type'): WS_TYPE_LIST, diff --git a/homeassistant/components/config/entity_registry.py b/homeassistant/components/config/entity_registry.py index 39dd622540d..341b05f966b 100644 --- a/homeassistant/components/config/entity_registry.py +++ b/homeassistant/components/config/entity_registry.py @@ -9,8 +9,6 @@ from homeassistant.components.websocket_api.decorators import ( async_response, require_admin) from homeassistant.helpers import config_validation as cv -DEPENDENCIES = ['websocket_api'] - WS_TYPE_LIST = 'config/entity_registry/list' SCHEMA_WS_LIST = websocket_api.BASE_COMMAND_MESSAGE_SCHEMA.extend({ vol.Required('type'): WS_TYPE_LIST,