set regardless, there is no need for the check

This commit is contained in:
Victor Shyba 2019-12-11 23:19:18 -03:00 committed by Lex Berezhny
parent aaa9982932
commit 82ef76b1cb

View file

@ -23,5 +23,4 @@ class TaskGroup:
def cancel(self):
for task in self._tasks:
task.cancel()
if len(self._tasks) < 1:
self.done.set()
self.done.set()