Fix growat server config entry missing URL key (#53867)

This commit is contained in:
Franck Nijhof 2021-08-02 18:48:17 +02:00 committed by GitHub
parent b2725918b1
commit 3bf06de363
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -598,7 +598,7 @@ async def async_setup_entry(hass, config_entry, async_add_entities):
config = config_entry.data
username = config[CONF_USERNAME]
password = config[CONF_PASSWORD]
url = config[CONF_URL]
url = config.get(CONF_URL, DEFAULT_URL)
name = config[CONF_NAME]
api = growattServer.GrowattApi()