Import ns itself, and remove the _NS suffix on all namespaces.

This commit is contained in:
Emmanuel Gil Peyrot 2017-04-20 23:16:12 +01:00
commit 7288c2c74f
10 changed files with 47 additions and 47 deletions

View file

@ -2,14 +2,14 @@ use minidom::Element;
use error::Error;
use ns::PING_NS;
use ns;
#[derive(Debug)]
pub struct Ping {
}
pub fn parse_ping(root: &Element) -> Result<Ping, Error> {
if !root.is("ping", PING_NS) {
if !root.is("ping", ns::PING) {
return Err(Error::ParseError("This is not a ping element."));
}