ripple-api/app/websockets/entry.go

19 lines
373 B
Go
Raw Permalink Normal View History

2017-02-19 17:19:59 +00:00
package websockets
import (
"github.com/leavengood/websocket"
"github.com/valyala/fasthttp"
)
var upgrader = websocket.FastHTTPUpgrader{
Handler: handler,
CheckOrigin: func(ctx *fasthttp.RequestCtx) bool {
return true
},
}
// WebsocketV1Entry upgrades a connection to a websocket.
func WebsocketV1Entry(ctx *fasthttp.RequestCtx) {
upgrader.UpgradeHandler(ctx)
}