File tree Expand file tree Collapse file tree 3 files changed +4
-5
lines changed
Expand file tree Collapse file tree 3 files changed +4
-5
lines changed Original file line number Diff line number Diff line change 1+ analyzer :
2+ strong-mode : true
Original file line number Diff line number Diff line change 55import 'dart:convert' ;
66
77import 'package:shelf/shelf.dart' ;
8- import 'package:stream_channel/stream_channel.dart' ;
98import 'package:web_socket_channel/web_socket_channel.dart' ;
109
1110/// A class that exposes a handler for upgrading WebSocket requests.
@@ -65,9 +64,7 @@ class WebSocketHandler {
6564 }
6665
6766 var protocol = _chooseProtocol (request);
68- request.hijack ((untypedChannel) {
69- var channel = (untypedChannel as StreamChannel ).cast <List <int >>();
70-
67+ request.hijack ((channel) {
7168 var sink = UTF8 .encoder.startChunkedConversion (channel.sink);
7269 sink.add (
7370 "HTTP/1.1 101 Switching Protocols\r\n "
Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ homepage: http://github.com/dart-lang/shelf_web_socket
55description : >
66 A WebSocket handler for Shelf.
77dependencies :
8- shelf : " >=0.6.5 <0.8.0"
8+ shelf : " >=0.7.0 <0.8.0"
99 stream_channel : " ^1.4.0"
1010 web_socket_channel : " ^1.0.0"
1111dev_dependencies :
You can’t perform that action at this time.
0 commit comments