Skip to content

Commit 6b08205

Browse files
committed
fix: check types
1 parent e6fe9e0 commit 6b08205

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

taskiq/middlewares/smart_retry_middleware.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@
33
import datetime
44
import random
55
from logging import getLogger
6-
from types import NoneType
76
from typing import Any
87

98
from taskiq import ScheduleSource
@@ -62,7 +61,7 @@ def __init__(
6261
self.max_delay_exponent = max_delay_exponent
6362
self.schedule_source = schedule_source
6463

65-
if not isinstance(schedule_source, (ScheduleSource, NoneType)):
64+
if not isinstance(schedule_source, (ScheduleSource, type(None))):
6665
raise TypeError(
6766
"schedule_source must be an instance of ScheduleSource or None",
6867
)

0 commit comments

Comments
 (0)