Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address flume post merge review comments #102807

Merged
merged 3 commits into from
Nov 10, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
8 changes: 5 additions & 3 deletions homeassistant/components/flume/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
ServiceCall,
ServiceResponse,
SupportsResponse,
callback,
)
from homeassistant.exceptions import ConfigEntryAuthFailed, ConfigEntryNotReady
from homeassistant.helpers.selector import ConfigEntrySelector
Expand Down Expand Up @@ -88,7 +89,7 @@ async def async_setup_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
}

await hass.config_entries.async_forward_entry_setups(entry, PLATFORMS)
await async_setup_service(hass)
setup_service(hass)

return True

Expand All @@ -105,10 +106,11 @@ async def async_unload_entry(hass: HomeAssistant, entry: ConfigEntry) -> bool:
return unload_ok


async def async_setup_service(hass: HomeAssistant) -> None:
def setup_service(hass: HomeAssistant) -> None:
"""Add the services for the flume integration."""

async def list_notifications(call: ServiceCall) -> ServiceResponse:
@callback
def list_notifications(call: ServiceCall) -> ServiceResponse:
tronikos marked this conversation as resolved.
Show resolved Hide resolved
"""Return the user notifications."""
entry_id: str = call.data[CONF_CONFIG_ENTRY]
entry: ConfigEntry | None = hass.config_entries.async_get_entry(entry_id)
Expand Down