We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3b39cf2 commit 7c60274Copy full SHA for 7c60274
core/thread.py
@@ -334,10 +334,10 @@ async def _close(
334
await asyncio.gather(*tasks)
335
336
async def cancel_closure(self, auto_close: bool = False, all: bool = False) -> None:
337
- if self.close_task is not None and not auto_close or all:
+ if self.close_task is not None and (not auto_close or all):
338
self.close_task.cancel()
339
self.close_task = None
340
- if self.auto_close_task is not None and auto_close or all:
+ if self.auto_close_task is not None and (auto_close or all):
341
self.auto_close_task.cancel()
342
self.auto_close_task = None
343
0 commit comments