Skip to content

Commit dbcc418

Browse files
authored
Merge pull request #122 from evanpurkhiser/black-comments-whitespace
black: Comments + minor whitespace
2 parents d7507bf + c4b7c92 commit dbcc418

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

src/croniter/croniter.py

+9-5
Original file line numberDiff line numberDiff line change
@@ -491,6 +491,7 @@ def iter(self, *args, **kwargs):
491491

492492
def __iter__(self):
493493
return self
494+
494495
__next__ = next = _get_next
495496

496497
def _calc(self, now, expanded, nth_weekday_of_month, is_prev):
@@ -1273,10 +1274,10 @@ def croniter_range(
12731274
ret_type = auto_rt
12741275
if not exclude_ends:
12751276
ms1 = relativedelta(microseconds=1)
1276-
if start < stop: # Forward (normal) time order
1277+
if start < stop: # Forward (normal) time order
12771278
start -= ms1
12781279
stop += ms1
1279-
else: # Reverse time order
1280+
else: # Reverse time order
12801281
start += ms1
12811282
stop -= ms1
12821283
year_span = math.floor(abs(stop.year - start.year)) + 1
@@ -1285,13 +1286,17 @@ def croniter_range(
12851286
second_at_beginning=second_at_beginning,
12861287
expand_from_start_time=expand_from_start_time)
12871288
# define a continue (cont) condition function and step function for the main while loop
1288-
if start < stop: # Forward
1289+
if start < stop: # Forward
1290+
12891291
def cont(v):
12901292
return v < stop
1293+
12911294
step = ic.get_next
1292-
else: # Reverse
1295+
else: # Reverse
1296+
12931297
def cont(v):
12941298
return v > stop
1299+
12951300
step = ic.get_prev
12961301
try:
12971302
dt = step()
@@ -1307,7 +1312,6 @@ def cont(v):
13071312

13081313

13091314
class HashExpander:
1310-
13111315
def __init__(self, cronit):
13121316
self.cron = cronit
13131317

0 commit comments

Comments
 (0)