Skip to content

Commit

Permalink
"FlowResult" => "ConfigFlowResult"
Browse files Browse the repository at this point in the history
  • Loading branch information
amitfin committed Nov 3, 2024
1 parent 6a897f6 commit 9b5b7fb
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 9 deletions.
18 changes: 10 additions & 8 deletions custom_components/oref_alert/config_flow.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,18 +3,20 @@
from __future__ import annotations

import contextlib
from typing import TYPE_CHECKING, Any
from typing import Any

import homeassistant.helpers.config_validation as cv
import voluptuous as vol
from homeassistant.config_entries import ConfigEntry, ConfigFlow, OptionsFlow
from homeassistant.config_entries import (
ConfigEntry,
ConfigFlow,
ConfigFlowResult,
OptionsFlow,
)
from homeassistant.core import async_get_hass, callback
from homeassistant.exceptions import HomeAssistantError
from homeassistant.helpers import selector

if TYPE_CHECKING:
from homeassistant.data_entry_flow import FlowResult

from .const import (
CONF_ALERT_ACTIVE_DURATION,
CONF_AREAS,
Expand Down Expand Up @@ -51,7 +53,7 @@ def __init__(self) -> None:

async def async_step_user(
self, user_input: dict[str, Any] | None = None
) -> FlowResult:
) -> ConfigFlowResult:
"""Handle a flow initialized by the user."""
if self._async_current_entries():
return self.async_abort(reason="single_instance_allowed")
Expand All @@ -74,7 +76,7 @@ async def async_step_user(

async def async_step_confirm(
self, user_input: dict[str, Any] | None = None
) -> FlowResult:
) -> ConfigFlowResult:
"""Confirm the setup."""
if user_input is not None:
return self.async_create_entry(
Expand Down Expand Up @@ -107,7 +109,7 @@ def __init__(self, config_entry: ConfigEntry) -> None:
"""Initialize options flow."""
self._config_entry = config_entry

async def async_step_init(self, user_input: dict[str, Any]) -> FlowResult:
async def async_step_init(self, user_input: dict[str, Any]) -> ConfigFlowResult:
"""Handle an options flow."""
if user_input is not None:
return self.async_create_entry(
Expand Down
2 changes: 1 addition & 1 deletion hacs.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"IL"
],
"hide_default_branch": true,
"homeassistant": "2023.1.0",
"homeassistant": "2024.4.0",
"render_readme": true,
"zip_release": true
}

0 comments on commit 9b5b7fb

Please sign in to comment.