elaborate error macro and apply at various callsites
Signed-off-by: Jason Volk <jason@zemos.net>
This commit is contained in:
parent
b3f2288d07
commit
05efd9b044
23 changed files with 161 additions and 140 deletions
|
@ -6,7 +6,7 @@ mod sender;
|
|||
|
||||
use std::fmt::Debug;
|
||||
|
||||
use conduit::{Error, Result};
|
||||
use conduit::{err, Result};
|
||||
pub use resolve::{resolve_actual_dest, CachedDest, CachedOverride, FedDest};
|
||||
use ruma::{
|
||||
api::{appservice::Registration, OutgoingRequest},
|
||||
|
@ -224,7 +224,7 @@ impl Service {
|
|||
fn dispatch(&self, msg: Msg) -> Result<()> {
|
||||
debug_assert!(!self.sender.is_full(), "channel full");
|
||||
debug_assert!(!self.sender.is_closed(), "channel closed");
|
||||
self.sender.send(msg).map_err(|e| Error::Err(e.to_string()))
|
||||
self.sender.send(msg).map_err(|e| err!("{e}"))
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue