Commit a1721eeb authored by Taddeüs Kroes's avatar Taddeüs Kroes

Changed receive() to recv() on Connection class to generalize the API

parent ba21de4a
......@@ -39,7 +39,7 @@ class Connection(object):
else:
self.sock.send(*message.fragment(fragment_size, mask=mask))
def receive(self):
def recv(self):
"""
Receive a message. A message may consist of multiple (ordered) data
frames. A control frame may be delivered at any time, also when
......@@ -103,7 +103,7 @@ class Connection(object):
"""
while True:
try:
self.onmessage(self.receive())
self.onmessage(self.recv())
except SocketClosed as e:
self.close(e.code, e.reason)
break
......
......@@ -237,7 +237,6 @@ class ClientHandshake(Handshake):
self.wsock.protocol = protocol
def handle_auth(self, headers):
# HTTP authentication is required in the request
hdr = headers['WWW-Authenticate']
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment