Skip to content

Commit

Permalink
Make implicit optional explicit (#567)
Browse files Browse the repository at this point in the history
  • Loading branch information
masa-08 committed Apr 9, 2023
1 parent 3eac646 commit 010236b
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions schedule/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -223,7 +223,7 @@ class Job(object):
method, which also defines its `interval`.
"""

def __init__(self, interval: int, scheduler: Scheduler = None):
def __init__(self, interval: int, scheduler: Optional[Scheduler] = None):
self.interval: int = interval # pause interval * unit between runs
self.latest: Optional[int] = None # upper limit to the interval
self.job_func: Optional[functools.partial] = None # the job job_func to run
Expand Down Expand Up @@ -465,7 +465,7 @@ def tag(self, *tags: Hashable):
self.tags.update(tags)
return self

def at(self, time_str: str, tz: str = None):
def at(self, time_str: str, tz: Optional[str] = None):

"""
Specify a particular time that the job should be run at.
Expand Down

0 comments on commit 010236b

Please sign in to comment.