Skip to content

Commit 654ed50

Browse files
authored
Also catch ValueError when converting timestamp to datetime (#1329)
1 parent e3d90a5 commit 654ed50

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

plexapi/utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,7 @@ def toDatetime(value, format=None):
329329
return None
330330
try:
331331
return datetime.fromtimestamp(value)
332-
except (OSError, OverflowError):
332+
except (OSError, OverflowError, ValueError):
333333
try:
334334
return datetime.fromtimestamp(0) + timedelta(seconds=value)
335335
except OverflowError:

0 commit comments

Comments
 (0)