Remove the MessagePayload trait, it was a bad idea.

This commit is contained in:
Emmanuel Gil Peyrot 2017-04-20 00:14:47 +01:00
commit a9993b1281
3 changed files with 8 additions and 11 deletions

View file

@ -1,7 +1,6 @@
use minidom::Element;
use error::Error;
use super::MessagePayload;
// TODO: also support components and servers.
use ns::JABBER_CLIENT_NS;
@ -11,8 +10,6 @@ pub struct Body {
body: String,
}
impl MessagePayload for Body {}
pub fn parse_body(root: &Element) -> Result<Body, Error> {
if !root.is("body", JABBER_CLIENT_NS) {
return Err(Error::ParseError("This is not a body element."));