mirror of
https://git.asonix.dog/asonix/pict-rs
synced 2024-11-09 22:14:59 +00:00
Tweak error reporting
This commit is contained in:
parent
1538389caf
commit
71f8f52b58
1 changed files with 2 additions and 1 deletions
|
@ -45,7 +45,7 @@ impl std::fmt::Display for Error {
|
||||||
|
|
||||||
impl std::error::Error for Error {
|
impl std::error::Error for Error {
|
||||||
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
|
fn source(&self) -> Option<&(dyn std::error::Error + 'static)> {
|
||||||
self.inner.source()
|
Some(self.inner.as_ref())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -53,6 +53,7 @@ impl<T> From<T> for Error
|
||||||
where
|
where
|
||||||
UploadError: From<T>,
|
UploadError: From<T>,
|
||||||
{
|
{
|
||||||
|
#[track_caller]
|
||||||
fn from(error: T) -> Self {
|
fn from(error: T) -> Self {
|
||||||
let inner = Report::from(UploadError::from(error));
|
let inner = Report::from(UploadError::from(error));
|
||||||
let debug = Arc::from(format!("{inner:?}"));
|
let debug = Arc::from(format!("{inner:?}"));
|
||||||
|
|
Loading…
Reference in a new issue