1
0
mirror of https://github.com/actix/actix-extras.git synced 2025-06-25 01:51:23 +02:00

added WsWriter::close

This commit is contained in:
Nikolay Kim
2017-10-29 19:49:59 -07:00
parent 8ab04b39df
commit dec4140733
4 changed files with 19 additions and 10 deletions

View File

@ -82,7 +82,7 @@ impl Handler<ws::Message> for WsChatSession {
println!("WEBSOCKET MESSAGE: {:?}", msg);
match msg {
ws::Message::Ping(msg) =>
ws::WsWriter::pong(ctx, msg),
ws::WsWriter::pong(ctx, &msg),
ws::Message::Pong(msg) =>
self.hb = Instant::now(),
ws::Message::Text(text) => {