revert(protobuf): Remove protobuf for now

This commit is contained in:
Wanjohi
2025-01-28 20:23:28 +03:00
parent fbaa8835a3
commit be6ea11052
38 changed files with 652 additions and 2763 deletions

View File

@@ -1,7 +1,6 @@
package relay
import (
"encoding/json"
"github.com/gorilla/websocket"
"log"
"net/http"
@@ -82,7 +81,7 @@ func wsHandler(w http.ResponseWriter, r *http.Request) {
// Assign message handler for join request
ws.RegisterMessageCallback("join", func(data []byte) {
var joinMsg MessageJoin
if err = json.Unmarshal(data, &joinMsg); err != nil {
if err = DecodeMessage(data, &joinMsg); err != nil {
log.Printf("Failed to decode join message: %s\n", err)
return
}