diff --git a/homeassistant/components/isy994/__init__.py b/homeassistant/components/isy994/__init__.py index 2f3b56aad0d..5d4603cafc0 100644 --- a/homeassistant/components/isy994/__init__.py +++ b/homeassistant/components/isy994/__init__.py @@ -47,7 +47,7 @@ from .const import ( ) from .helpers import _categorize_nodes, _categorize_programs from .models import IsyConfigEntry, IsyData -from .services import async_setup_services, async_unload_services +from .services import async_setup_services from .util import _async_cleanup_registry_entries CONFIG_SCHEMA = vol.Schema( @@ -227,9 +227,6 @@ async def async_unload_entry(hass: HomeAssistant, entry: IsyConfigEntry) -> bool _LOGGER.debug("ISY Stopping Event Stream and automatic updates") entry.runtime_data.root.websocket.stop() - if not hass.config_entries.async_loaded_entries(DOMAIN): - async_unload_services(hass) - return unload_ok diff --git a/homeassistant/components/isy994/services.py b/homeassistant/components/isy994/services.py index 39f72a5cc2c..3f31b2e5730 100644 --- a/homeassistant/components/isy994/services.py +++ b/homeassistant/components/isy994/services.py @@ -137,10 +137,6 @@ def async_get_entities(hass: HomeAssistant) -> dict[str, Entity]: @callback def async_setup_services(hass: HomeAssistant) -> None: """Create and register services for the ISY integration.""" - existing_services = hass.services.async_services_for_domain(DOMAIN) - if existing_services and SERVICE_SEND_PROGRAM_COMMAND in existing_services: - # Integration-level services have already been added. Return. - return async def async_send_program_command_service_handler(service: ServiceCall) -> None: """Handle a send program command service call.""" @@ -230,18 +226,3 @@ def async_setup_services(hass: HomeAssistant) -> None: schema=cv.make_entity_service_schema(SERVICE_RENAME_NODE_SCHEMA), service_func=_async_rename_node, ) - - -@callback -def async_unload_services(hass: HomeAssistant) -> None: - """Unload services for the ISY integration.""" - existing_services = hass.services.async_services_for_domain(DOMAIN) - if not existing_services or SERVICE_SEND_PROGRAM_COMMAND not in existing_services: - return - - _LOGGER.debug("Unloading ISY994 Services") - hass.services.async_remove(domain=DOMAIN, service=SERVICE_SEND_PROGRAM_COMMAND) - hass.services.async_remove(domain=DOMAIN, service=SERVICE_SEND_RAW_NODE_COMMAND) - hass.services.async_remove(domain=DOMAIN, service=SERVICE_SEND_NODE_COMMAND) - hass.services.async_remove(domain=DOMAIN, service=SERVICE_GET_ZWAVE_PARAMETER) - hass.services.async_remove(domain=DOMAIN, service=SERVICE_SET_ZWAVE_PARAMETER)