summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--utils.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/utils.py b/utils.py
index 8b688a6..44fd07a 100644
--- a/utils.py
+++ b/utils.py
@@ -52,7 +52,7 @@ def adjacent(p: Point2D[int], diagonal: bool = True) -> Iterator[Point2D[int]]:
for dx in range(-1, 2):
for dy in range(-1, 2):
if dx == 0 and dy == 0: continue
- if dx != 0 and dy != 0 and not adjacent: continue
+ if dx != 0 and dy != 0 and not diagonal: continue
yield Point2D(p.x + dx, p.y + dy)
def adjacent_bounded(p: Point2D[int], bound: Point2D[int], diagonal: bool = True) \