echo_bot: use xmpp-parsers to parse message

This commit is contained in:
Astro 2017-07-20 01:07:07 +02:00
commit 00e2daaecd
2 changed files with 20 additions and 13 deletions

View file

@ -28,4 +28,11 @@ impl Event {
_ => None,
}
}
pub fn into_stanza(self) -> Option<Element> {
match self {
Event::Stanza(stanza) => Some(stanza),
_ => None,
}
}
}