Export Error and Result at top level
This commit is contained in:
parent
eca41c7d25
commit
8fbf77a2d7
4 changed files with 6 additions and 6 deletions
|
|
@ -5,7 +5,7 @@
|
||||||
use serde::{Deserialize, Serialize};
|
use serde::{Deserialize, Serialize};
|
||||||
use serde_json::Value;
|
use serde_json::Value;
|
||||||
|
|
||||||
use crate::error::{self, Error};
|
use crate::Error;
|
||||||
|
|
||||||
use super::PacketType;
|
use super::PacketType;
|
||||||
|
|
||||||
|
|
@ -229,7 +229,7 @@ impl ParsedPacket {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn into_data(self) -> error::Result<Data> {
|
pub fn into_data(self) -> crate::Result<Data> {
|
||||||
self.content.map_err(Error::Euph)
|
self.content.map_err(Error::Euph)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,8 +13,8 @@ use tokio_tungstenite::tungstenite::{
|
||||||
use crate::{
|
use crate::{
|
||||||
api::{Command, Data, ParsedPacket},
|
api::{Command, Data, ParsedPacket},
|
||||||
conn::{Conn, ConnConfig, Side},
|
conn::{Conn, ConnConfig, Side},
|
||||||
error::{Error, Result},
|
|
||||||
replies::{self, PendingReply, Replies},
|
replies::{self, PendingReply, Replies},
|
||||||
|
Error, Result,
|
||||||
};
|
};
|
||||||
|
|
||||||
use super::state::State;
|
use super::state::State;
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ use tokio_tungstenite::{
|
||||||
|
|
||||||
use crate::{
|
use crate::{
|
||||||
api::{Data, Packet, PacketType, ParsedPacket, Ping, PingEvent, PingReply, Time},
|
api::{Data, Packet, PacketType, ParsedPacket, Ping, PingEvent, PingReply, Time},
|
||||||
error::{Error, Result},
|
Error, Result,
|
||||||
};
|
};
|
||||||
|
|
||||||
/// Which side of the connection we're on.
|
/// Which side of the connection we're on.
|
||||||
|
|
|
||||||
|
|
@ -2,8 +2,8 @@ pub mod api;
|
||||||
pub mod client;
|
pub mod client;
|
||||||
pub mod conn;
|
pub mod conn;
|
||||||
mod emoji;
|
mod emoji;
|
||||||
pub mod error;
|
mod error;
|
||||||
pub mod nick;
|
pub mod nick;
|
||||||
mod replies;
|
mod replies;
|
||||||
|
|
||||||
pub use crate::emoji::Emoji;
|
pub use crate::{emoji::*, error::*};
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue