From 3af54223846263afbe316a390dbc44a07714c95b Mon Sep 17 00:00:00 2001 From: Nguyen Trung Loi Date: Sat, 19 May 2018 20:03:20 +0700 Subject: [PATCH] Fix wrong listener in README.md (#18) --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2ea4408dd8d39..c1abd7a529d7a 100644 --- a/README.md +++ b/README.md @@ -91,7 +91,7 @@ import 'package:web_socket_channel/io.dart'; main() async { var channel = new IOWebSocketChannel.connect("ws://localhost:8181"); channel.sink.add("connected!"); - channel.sink.listen((message) { + channel.stream.listen((message) { // ... }); } @@ -120,7 +120,7 @@ import 'package:web_socket_channel/html.dart'; main() async { var channel = new HtmlWebSocketChannel.connect("ws://localhost:8181"); channel.sink.add("connected!"); - channel.sink.listen((message) { + channel.stream.listen((message) { // ... }); }