From e893869df974ebb7afcc318119840c53f8f377cb Mon Sep 17 00:00:00 2001 From: cel 🌸 Date: Sat, 21 Oct 2023 01:28:54 +0100 Subject: implement connection --- src/error.rs | 19 +------------------ 1 file changed, 1 insertion(+), 18 deletions(-) (limited to 'src/error.rs') diff --git a/src/error.rs b/src/error.rs index 9278f1b..b12914c 100644 --- a/src/error.rs +++ b/src/error.rs @@ -3,10 +3,7 @@ use std::str::Utf8Error; use quick_xml::events::attributes::AttrError; use rsasl::mechname::MechanismNameError; -use crate::{ - jid::ParseError, - stanza::{self, ElementError, ElementParseError}, -}; +use crate::jid::ParseError; #[derive(Debug)] pub enum JabberError { @@ -22,14 +19,12 @@ pub enum JabberError { NoType, IDMismatch, BindError, - ElementParse(ElementParseError), ParseError, UnexpectedEnd, UnexpectedElement, UnexpectedText, XML(quick_xml::Error), SASL(SASLError), - Element(ElementError<'static>), JID(ParseError), } @@ -71,12 +66,6 @@ impl From for JabberError { } } -impl From> for JabberError { - fn from(e: stanza::ElementError<'static>) -> Self { - Self::Element(e) - } -} - impl From for JabberError { fn from(e: AttrError) -> Self { Self::XML(e.into()) @@ -88,9 +77,3 @@ impl From for JabberError { Self::JID(e) } } - -impl From for JabberError { - fn from(e: ElementParseError) -> Self { - Self::ElementParse(e) - } -} -- cgit