Skip to content

Commit 33996e0

Browse files
committed
Reduced recursion
1 parent d843f5d commit 33996e0

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

neo4j/v1/session.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,8 @@ def __next__(self):
212212
elif self._consumed:
213213
raise StopIteration()
214214
else:
215-
self.connection.fetch()
215+
while not self._buffer and not self._consumed:
216+
self.connection.fetch()
216217
return self.__next__()
217218

218219
def __iter__(self):

0 commit comments

Comments
 (0)