func CreateHandshakePacket(sid string, transport transport.Transport, config config.Config) packet.Packet {
	handshake := handshakeMessage{
		SessionID:    sid,
		PingInterval: int64(config.PingInterval / time.Millisecond),
		PingTimeout:  int64(config.PingTimeout / time.Millisecond),
		Upgrades:     getSupportedUpgrades(transport, config),
	}

	json, _ := json.Marshal(handshake)

	return packet.NewOpen(json)
}
// CreateHandshakePacket creates open packet with JSON serialized handshake messag
CreateHandshakePacket creates open packet with JSON serialized handshake messag
// CreateHandshakePacket creates open packet with JSON serialized handshake messag
func CreateHandshakePacket(sid string, transport transport.Transport, config config.Config) packet.Packet {
	handshake := handshakeMessage{
		SessionID:    sid,
		PingInterval: int64(config.PingInterval / time.Millisecond),
		PingTimeout:  int64(config.PingTimeout / time.Millisecond),
		Upgrades:     getSupportedUpgrades(transport, config),
	}
	json, _ := json.Marshal(handshake)
	return packet.NewOpen(json)
}
func CreateHandshakePacket ( sid string , transport transport . Transport , config config . Config ) packet . Packet { handshake := handshakeMessage { SessionID : sid , PingInterval : int64 ( config . PingInterval / time . Millisecond ) , PingTimeout : int64 ( config . PingTimeout / time . Millisecond ) , Upgrades : getSupportedUpgrades ( transport , config ) , } json , _ := json . Marshal ( handshake ) return packet . NewOpen ( json ) }
CreateHandshakePacket creates open packet with JSON serialized handshake messag
CreateHandshakePacket creates open packet with JSON serialized handshake messag