Browse Source

assigning local ret variable to none if the asyncio task is canceled (#164)

pull/167/head
rettier 7 years ago
committed by Miguel Grinberg
parent
commit
598568c715
  1. 2
      socketio/asyncio_namespace.py

2
socketio/asyncio_namespace.py

@ -36,7 +36,7 @@ class AsyncNamespace(namespace.Namespace):
try: try:
ret = await handler(*args) ret = await handler(*args)
except asyncio.CancelledError: # pragma: no cover except asyncio.CancelledError: # pragma: no cover
pass ret = None
else: else:
ret = handler(*args) ret = handler(*args)
return ret return ret

Loading…
Cancel
Save