Update __init__.py

This commit is contained in:
Guy Khmelnitsky
2021-12-16 17:36:15 +02:00
committed by GitHub
parent eeb41fe7cd
commit 3dd57f24ac

View File

@@ -111,7 +111,7 @@ class GlancesData:
async def async_update(self): async def async_update(self):
"""Get the latest data from the Glances REST API.""" """Get the latest data from the Glances REST API."""
try: try:
await self.api.get_data() await self.api.get_data("all")
self.available = True self.available = True
except exceptions.GlancesApiError: except exceptions.GlancesApiError:
_LOGGER.error("Unable to fetch data from Glances") _LOGGER.error("Unable to fetch data from Glances")
@@ -123,7 +123,7 @@ class GlancesData:
"""Set up the Glances client.""" """Set up the Glances client."""
try: try:
self.api = get_api(self.hass, self.config_entry.data) self.api = get_api(self.hass, self.config_entry.data)
await self.api.get_data() await self.api.get_data("all")
self.available = True self.available = True
_LOGGER.debug("Successfully connected to Glances") _LOGGER.debug("Successfully connected to Glances")