Browse Source

Support optional payloads in msgpack implementation (#981)

pull/995/head
Cromfel 3 years ago
committed by GitHub
parent
commit
ce1afd79e6
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/socketio/msgpack_packet.py

2
src/socketio/msgpack_packet.py

@ -13,6 +13,6 @@ class MsgPackPacket(packet.Packet):
"""Decode a transmitted package."""
decoded = msgpack.loads(encoded_packet)
self.packet_type = decoded['type']
self.data = decoded['data']
self.data = decoded.get('data')
self.id = decoded.get('id')
self.namespace = decoded['nsp']

Loading…
Cancel
Save