Really fixed error from raising StopIteration in a coroutine.
This commit is contained in:
parent
3b1da7537f
commit
a5cc1163c1
1 changed files with 2 additions and 3 deletions
|
|
@ -412,10 +412,9 @@ class Summary:
|
|||
yield result
|
||||
|
||||
async def get_closest_placeholder(self):
|
||||
try:
|
||||
return self.closest_placeholder_generator.send(None)
|
||||
except AttributeError:
|
||||
if self.closest_placeholder_generator is None:
|
||||
self.closest_placeholder_generator = self._placeholder_sweep()
|
||||
try:
|
||||
return self.closest_placeholder_generator.send(None)
|
||||
except StopIteration:
|
||||
raise StopAsyncIteration
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue