1
0
mirror of https://github.com/kataras/iris.git synced 2025-12-18 18:37:05 +00:00

Update to version 11.0.1. Feature request implemented: https://github.com/kataras/iris/issues/1113

Former-commit-id: 0ce38dbacc2458fe327fa4401fdde1e69c8aacb0
This commit is contained in:
Gerasimos (Makis) Maropoulos
2018-10-28 01:19:22 +03:00
parent 8950ae7bb9
commit be32418bc1
16 changed files with 272 additions and 159 deletions

View File

@@ -89,7 +89,7 @@ func SendMessage(serverID, to, method, message string) error {
func SendtBytes(serverID, to, method string, message []byte) error {
// look https://github.com/kataras/iris/blob/master/websocket/message.go , client.go and client.js
// to understand the buffer line:
buffer := []byte(fmt.Sprintf("iris-websocket-message:%v;0;%v;%v;", method, serverID, to))
buffer := []byte(fmt.Sprintf("%s%v;0;%v;%v;", websocket.DefaultEvtMessageKey, method, serverID, to))
buffer = append(buffer, message...)
_, err := WS.Write(buffer)
if err != nil {