mirror of
https://github.com/m1k1o/neko.git
synced 2026-11-03 08:21:50 -06:00
ignore irrelevant legacy ws events.
This commit is contained in:
@@ -432,6 +432,10 @@ func (s *session) wsToClient(msg []byte) error {
|
|||||||
return nil
|
return nil
|
||||||
|
|
||||||
// Signal Events
|
// Signal Events
|
||||||
|
case event.SIGNAL_VIDEO, event.SIGNAL_AUDIO:
|
||||||
|
// ignore video and audio signals, because they are not part of the legacy protocol
|
||||||
|
return nil
|
||||||
|
|
||||||
case event.SIGNAL_OFFER:
|
case event.SIGNAL_OFFER:
|
||||||
request := &message.SignalDescription{}
|
request := &message.SignalDescription{}
|
||||||
err := json.Unmarshal(data.Payload, request)
|
err := json.Unmarshal(data.Payload, request)
|
||||||
@@ -543,6 +547,10 @@ func (s *session) wsToClient(msg []byte) error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Chat Events
|
// Chat Events
|
||||||
|
case chat.CHAT_INIT:
|
||||||
|
// ignore chat init, because it is not part of the legacy protocol
|
||||||
|
return nil
|
||||||
|
|
||||||
case chat.CHAT_MESSAGE:
|
case chat.CHAT_MESSAGE:
|
||||||
request := &chat.Message{}
|
request := &chat.Message{}
|
||||||
err := json.Unmarshal(data.Payload, request)
|
err := json.Unmarshal(data.Payload, request)
|
||||||
|
|||||||
Reference in New Issue
Block a user