diff --git a/examples/websocket-chat/src/main.rs b/examples/websocket-chat/src/main.rs index 509192f00..9c9af18e5 100644 --- a/examples/websocket-chat/src/main.rs +++ b/examples/websocket-chat/src/main.rs @@ -64,7 +64,7 @@ impl Actor for WsChatSession { // routes within application let addr: SyncAddress<_> = ctx.address(); ctx.state().addr.call( - self, server::Connect{addr: addr.into_subscriber()}).then( + self, server::Connect{addr: addr.into()}).then( |res, act, ctx| { match res { Ok(Ok(res)) => act.id = res, diff --git a/examples/websocket-chat/src/server.rs b/examples/websocket-chat/src/server.rs index 4eae86d00..477a401be 100644 --- a/examples/websocket-chat/src/server.rs +++ b/examples/websocket-chat/src/server.rs @@ -13,7 +13,7 @@ use session; /// New chat session is created pub struct Connect { - pub addr: Box + Send>, + pub addr: SyncSubscriber, } /// Response type for Connect message @@ -61,7 +61,7 @@ pub struct Join { /// `ChatServer` manages chat rooms and responsible for coordinating chat session. /// implementation is super primitive pub struct ChatServer { - sessions: HashMap + Send>>, + sessions: HashMap>, rooms: HashMap>, rng: RefCell, } diff --git a/examples/websocket-chat/src/session.rs b/examples/websocket-chat/src/session.rs index 5bc799ca7..29fcb9895 100644 --- a/examples/websocket-chat/src/session.rs +++ b/examples/websocket-chat/src/session.rs @@ -46,7 +46,7 @@ impl Actor for ChatSession { // future within context, but context waits until this future resolves // before processing any other events. let addr: SyncAddress<_> = ctx.address(); - self.addr.call(self, server::Connect{addr: addr.into_subscriber()}) + self.addr.call(self, server::Connect{addr: addr.into()}) .then(|res, act, ctx| { match res { Ok(Ok(res)) => act.id = res,