Not working OnEvent Method with return string
sshaplygin opened this issue · comments
Semen Shaplygin commented
Describe the bug
Expect similar behaviour for double methods: OnEvent with Emit and OnEvent with return string
To Reproduce
use simple example from https://github.com/socketio/chat-example
server.OnEvent("/", "chat message", func(s socketio.Conn, msg string) {
s.Emit("chat message", "have: "+msg)
})
server.OnEvent("/", "chat message", func(s socketio.Conn, msg string) string {
return "recv " + msg
})
client accept message by websocket, but it doesn't output by ui. maybe problem into socketio js. client
Expected behavior
server in event with return must be working.
Environment (please complete the following information):
- Go version: [v1.19]
- Server version [master - 913e8c2]
- Client version [v1.7.4]
Additional context
Add any other context about the problem here.