Skip to content

Commit

Permalink
Fix non int minor number
Browse files Browse the repository at this point in the history
  • Loading branch information
BenPru authored Mar 2, 2024
1 parent 973af26 commit 6ad33e6
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion custom_components/luxtronik/coordinator.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
from __future__ import annotations

import asyncio
import re
from collections.abc import Awaitable, Callable, Coroutine, Mapping
from functools import wraps
import threading
Expand Down Expand Up @@ -319,7 +320,7 @@ def firmware_version_minor(self) -> int:
ver = self.firmware_version
if ver is None:
return 0
return int(ver.split(".")[1])
return int(re.sub('[^0-9]','', ver.split(".")[1]))

def entity_visible(self, description: LuxtronikEntityDescription) -> bool:
"""Is description visible."""
Expand Down

0 comments on commit 6ad33e6

Please sign in to comment.