This commit is contained in:
crusader 2017-12-08 21:37:57 +09:00
parent a5e92f2b11
commit d4a7836ef7

View File

@ -114,7 +114,7 @@ func (u *Upgrader) Upgrade(ctx *fasthttp.RequestCtx, responseHeader *fasthttp.Re
} }
if nil != responseHeader { if nil != responseHeader {
if v := responseHeader.Peek("Sec-Websocket-Extensions"); nil == v { if v := responseHeader.Peek("Sec-Websocket-Extensions"); nil != v {
cb(u.returnError(ctx, fasthttp.StatusInternalServerError, "websocket: application specific 'Sec-Websocket-Extensions' headers are unsupported")) cb(u.returnError(ctx, fasthttp.StatusInternalServerError, "websocket: application specific 'Sec-Websocket-Extensions' headers are unsupported"))
return return
} }