Skip to content

Commit

Permalink
fix variable
Browse files Browse the repository at this point in the history
  • Loading branch information
cyr-ius committed Oct 22, 2022
1 parent e5dba5e commit 6c12435
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions custom_components/pdns/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,9 @@ def __init__(self, hass: HomeAssistant, entry: ConfigEntry) -> None:
)

async def _async_update_data(self) -> dict:
state = {}
try:
public_ip = await self.api.async_update()
state = await self.api.async_update()
except PDNSFailed as error:
_LOGGER.error(error)
return public_ip if public_ip else {}
return state
2 changes: 1 addition & 1 deletion custom_components/pdns/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
"issue_tracker": "https://github.com/Cyr-ius/hass-pdns/issues",
"codeowners": ["@Cyr-ius"],
"iot_class": "cloud_polling",
"version": "2.3.7"
"version": "2.3.8"
}

0 comments on commit 6c12435

Please sign in to comment.