From a92e7a0ff744ca5de7076f37741be830b93bb3f0 Mon Sep 17 00:00:00 2001 From: Astro Date: Thu, 24 Aug 2017 19:54:33 +0200 Subject: [PATCH] update deps --- Cargo.toml | 6 +++--- examples/echo_component.rs | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index b6c9a71..89e07ba 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,14 +10,14 @@ tokio-io = "*" bytes = "0.4.4" xml5ever = "*" tendril = "*" -minidom = "0.6.0" +minidom = "0.6.1" native-tls = "*" tokio-tls = "*" sasl = "*" rustc-serialize = "*" -jid = { version = "0.2.3", features = ["minidom"] } +jid = { version = "0.3.0", features = ["minidom"] } domain = "0.2.1" -xmpp-parsers = "0.7.0" +xmpp-parsers = "0.7.2" idna = "*" try_from = "0.2.2" sha-1 = "0.4.1" diff --git a/examples/echo_component.rs b/examples/echo_component.rs index 076bb17..ab38573 100644 --- a/examples/echo_component.rs +++ b/examples/echo_component.rs @@ -15,7 +15,7 @@ use futures::{Future, Stream, Sink, future}; use tokio_xmpp::Component; use minidom::Element; use xmpp_parsers::presence::{Presence, Type as PresenceType, Show as PresenceShow}; -use xmpp_parsers::message::{Message, MessageType}; +use xmpp_parsers::message::{Message, MessageType, Body}; use jid::Jid; fn main() { @@ -66,7 +66,7 @@ fn main() { match (message.from, message.bodies.get("")) { (Some(from), Some(body)) => if message.type_ != MessageType::Error { - let reply = make_reply(from, body); + let reply = make_reply(from, &body.0); send(reply); }, _ => (), @@ -99,6 +99,6 @@ fn make_presence(from: Jid, to: Jid) -> Element { // Construct a chat fn make_reply(to: Jid, body: &str) -> Element { let mut message = Message::new(Some(to)); - message.bodies.insert(String::new(), body.to_owned()); + message.bodies.insert(String::new(), Body(body.to_owned())); message.into() }