Inline single-use method compare_parser_and_def_default_namespaces()

This commit is contained in:
Dirkjan Ochtman 2022-09-04 15:39:06 +02:00
parent 2267863ae7
commit 6e0b105b8b
1 changed files with 1 additions and 5 deletions

View File

@ -51,10 +51,6 @@ impl<'xml> Deserializer<'xml> {
}
}
pub fn compare_parser_and_def_default_namespaces(&self) -> bool {
self.parser_default_namespace == self.def_default_namespace
}
pub fn peek_next_attribute(&self) -> Option<&(&'xml str, &'xml str)> {
self.tag_attributes.last()
}
@ -105,7 +101,7 @@ impl<'xml> Deserializer<'xml> {
}
// Compare parser namespace with defined one
if !self.compare_parser_and_def_default_namespaces() {
if self.parser_default_namespace != self.def_default_namespace {
return Err(Error::WrongNamespace);
}