2
0
mirror of https://github.com/xcat2/confluent.git synced 2025-01-28 03:48:35 +00:00

Fix python3-ism

python2 doesn't understand how to return
an iterator from within an iterator.
This commit is contained in:
Jarrod Johnson 2021-04-21 13:31:11 -04:00
parent 34cfd99fd8
commit d82690f0d9

View File

@ -463,7 +463,8 @@ def wsock_handler(ws):
def resourcehandler(env, start_response):
try:
if 'HTTP_SEC_WEBSOCKET_VERSION' in env:
return wsock_handler(env, start_response)
for rsp in wsock_handler(env, start_response):
yield rsp
for rsp in resourcehandler_backend(env, start_response):
yield rsp
except Exception as e: