Skip to content

Commit

Permalink
mypy
Browse files Browse the repository at this point in the history
  • Loading branch information
starkillerOG committed Feb 27, 2025
1 parent 2231839 commit 5672bf2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions reolink_aio/baichuan/baichuan.py
Original file line number Diff line number Diff line change
Expand Up @@ -817,12 +817,13 @@ def api_version(self, capability: str, channel: int | None = None, no_key_return
@property
def abilities(self) -> dict[int | str, Any]:
"""Return the abilities as a dictionary"""
abilities_dict = {}
abilities_dict: dict[int | str, dict[str, int | str]] = {}
for key, xml in self._abilities.items():
pretty_key = key if key is not None else "Host"
pretty_key: str | int = key if key is not None else "Host"
abilities_dict[pretty_key] = {}
for feature in xml:
if feature.text is not None:
value: int | str
try:
value = int(feature.text)
except ValueError:
Expand Down

0 comments on commit 5672bf2

Please sign in to comment.