Skip to content

Commit ec6c170

Browse files
fix: check for None explicitly to prevent incorrect behaviour when answer is 0
1 parent 0bb19b3 commit ec6c170

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/adventofcode/util/helpers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def wrapper(*args, **kwargs):
4444
start = time.perf_counter()
4545
solution = func(*args, **kwargs)
4646

47-
if not solution:
47+
if solution is None:
4848
raise SolutionNotFoundException(year, day, part)
4949

5050
diff = time.perf_counter() - start

0 commit comments

Comments
 (0)