Skip to content

Commit

Permalink
send() really shouldn't fail silently when getting an unknown data type
Browse files Browse the repository at this point in the history
  • Loading branch information
chadselph committed Feb 24, 2012
1 parent ce696c6 commit bb29e95
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions ws4py/websocket.py
Expand Up @@ -180,6 +180,9 @@ def send(self, payload, binary=False):
first = False

self.sender(message_sender(bytes).fragment(last=True, mask=self.stream.always_mask))

else:
raise ValueError("Unsupported type '%s' passed to send()" % type(payload))

def _cleanup(self):
"""
Expand Down

0 comments on commit bb29e95

Please sign in to comment.