diff --git a/server/main.go b/server/main.go index c5d2d4c..a0998c8 100644 --- a/server/main.go +++ b/server/main.go @@ -1,6 +1,8 @@ package server import ( + "encoding/json" + "fmt" "github.com/labstack/echo" "github.com/labstack/echo/engine/standard" "github.com/labstack/echo/middleware" @@ -43,7 +45,9 @@ func (s *Server) Start() { func projects() websocket.Handler { return websocket.Handler(func(ws *websocket.Conn) { for { - err := websocket.Message.Send(ws, "Hello") + message, _ := json.Marshal(Bp) + err := websocket.Message.Send(ws, string(message)) + fmt.Println(Bp) if err != nil { log.Fatal(err) }