Clean up access to config in various integrations v2 (#33763)
This commit is contained in:
1 parent
d95ffb3aa3
commit
d7e3b0b755
20 files changed
+59
-59
No files matched your search
@@ -37,8 +37,8 @@ CONFIG_SCHEMA = vol.Schema(
|
||||
def setup(hass, config):
|
||||
"""Use config values to set up a function enabling status retrieval."""
|
||||
conf = config[DOMAIN]
|
||||
host = conf.get(CONF_HOST)
|
||||
port = conf.get(CONF_PORT)
|
||||
host = conf[CONF_HOST]
|
||||
port = conf[CONF_PORT]
|
||||
|
||||
apcups_data = APCUPSdData(host, port)
|
||||
hass.data[DOMAIN] = apcups_data
|
||||
|
||||
Reference in new issue
Block a user