Use shared httpx client in iaqualink integration (#121407)

pull/121405/head^2
Florent Thoumie 2024-07-06 21:51:16 -07:00 committed by GitHub
parent 44f989ae38
commit 5ea1601c2c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 2 additions and 1 deletions

View File

@ -36,6 +36,7 @@ from homeassistant.helpers.dispatcher import (
)
from homeassistant.helpers.entity import Entity
from homeassistant.helpers.event import async_track_time_interval
from homeassistant.helpers.httpx_client import get_async_client
from .const import DOMAIN, UPDATE_INTERVAL
@ -67,7 +68,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
sensors = hass.data[DOMAIN][SENSOR_DOMAIN] = []
switches = hass.data[DOMAIN][SWITCH_DOMAIN] = []
aqualink = AqualinkClient(username, password)
aqualink = AqualinkClient(username, password, httpx_client=get_async_client(hass))
try:
await aqualink.login()
except AqualinkServiceException as login_exception: