Skip to content

Commit 7f6afd0

Browse files
committed
coverage
1 parent e22637b commit 7f6afd0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

onvif/types.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ def _try_parse_datetime(value: str) -> datetime | None:
2121

2222

2323
def _try_fix_time_overflow(time: str) -> tuple[str, dict[str, int]]:
24+
"""Some camera will overflow time so we need to fix it.
25+
26+
To do this we calculate the offset beyond the maximum value
27+
and then add it to the current time as a timedelta.
28+
"""
2429
offset: dict[str, int] = {}
2530
hour = int(time[0:2])
2631
if hour > 23:

0 commit comments

Comments
 (0)