Merge pull request #2558 from gqgs/ws-iterable

Avoid iterating in uninitialized result
This commit is contained in:
ZeroNet 2020-05-19 02:02:16 +02:00 committed by GitHub
commit f868fed51d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 0 deletions

View File

@ -262,6 +262,8 @@ class WebSocketHandler(WSGIHandler):
def process_result(self):
if "wsgi.websocket" in self.environ:
if self.result is None:
return
# Flushing result is required for werkzeug compatibility
for elem in self.result:
pass