Add the ability to reload the rest platforms from yaml (#39257)
* Add the ability to reload rest platforms from yaml * Revert changes to notify as these will be done in another pass
This commit is contained in:
1 parent
758c0adb5e
commit
5018e53b33
7 files changed
+77
-2
No files matched your search
@@ -29,7 +29,9 @@ from homeassistant.const import (
|
||||
)
|
||||
from homeassistant.exceptions import PlatformNotReady
|
||||
import homeassistant.helpers.config_validation as cv
|
||||
from homeassistant.helpers.reload import setup_reload_service
|
||||
|
||||
from . import DOMAIN, PLATFORMS
|
||||
from .sensor import RestData
|
||||
|
||||
_LOGGER = logging.getLogger(__name__)
|
||||
@@ -68,6 +70,9 @@ PLATFORM_SCHEMA = vol.All(
|
||||
|
||||
def setup_platform(hass, config, add_entities, discovery_info=None):
|
||||
"""Set up the REST binary sensor."""
|
||||
|
||||
setup_reload_service(hass, DOMAIN, PLATFORMS)
|
||||
|
||||
name = config.get(CONF_NAME)
|
||||
resource = config.get(CONF_RESOURCE)
|
||||
resource_template = config.get(CONF_RESOURCE_TEMPLATE)
|
||||
|
||||
Reference in new issue
Block a user