Skip to content

Commit

Permalink
Fix accesses hass.helpers.discovery is deprecated
Browse files Browse the repository at this point in the history
  • Loading branch information
Sdahl1234 authored May 5, 2024
1 parent f864737 commit bf3d342
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
6 changes: 2 additions & 4 deletions custom_components/seven_segments_alt/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,7 @@
from homeassistant.const import CONF_ENTITY_ID, CONF_NAME, Platform
from homeassistant.core import HomeAssistant
from homeassistant.helpers.device_registry import DeviceInfo

# from homeassistant.helpers.discovery import async_load_platform
from homeassistant.helpers.discovery import async_load_platform
from homeassistant.helpers.update_coordinator import DataUpdateCoordinator

# from . import ImageProcessingSsocr
Expand Down Expand Up @@ -49,8 +48,7 @@

async def async_setup(hass: HomeAssistant, config: ConfigType): # noqa: D103
hass.async_create_task(
hass.helpers.discovery.async_load_platform(
Platform.IMAGE_PROCESSING, DOMAIN, {}, config
async_load_platform(hass, Platform.IMAGE_PROCESSING, DOMAIN, {}, config
)
)
return True
Expand Down
2 changes: 1 addition & 1 deletion custom_components/seven_segments_alt/manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,5 +7,5 @@
"iot_class": "local_polling",
"requirements": ["Pillow==10.3.0"],
"config_flow": true,
"version": "1.0.3"
"version": "1.0.4"
}

0 comments on commit bf3d342

Please sign in to comment.