Accept "h2" as HTTP/2 in ALPN negotiations
commit394e1d36f52c1594ce8fd1f5393a26983d902412
authorAndrew Pritchard <awpr@google.com>
dateMon 3 Aug 2015, 13:41 (11 years ago)
parent53dba91
warp/Network/Wai/Handler/Warp/HTTP2/Types.hs+1−1
@@ -37,7 +37,7 @@ isHTTP2 tls = useHTTP2
3737 where
3838 useHTTP2 = case tlsNegotiatedProtocol tls of
3939 Nothing -> False
40− Just proto -> "h2-" `BS.isPrefixOf` proto
40+ Just proto -> "h2-" `BS.isPrefixOf` proto || proto == "h2"
4141
4242----------------------------------------------------------------
4343