aboutsummaryrefslogtreecommitdiff
path: root/src/api/error.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/api/error.rs')
-rw-r--r--src/api/error.rs6
1 files changed, 1 insertions, 5 deletions
diff --git a/src/api/error.rs b/src/api/error.rs
index 955faed1..8602cfdc 100644
--- a/src/api/error.rs
+++ b/src/api/error.rs
@@ -206,11 +206,7 @@ where
fn ok_or_bad_request<M: AsRef<str>>(self, reason: M) -> Result<T, Error> {
match self {
Ok(x) => Ok(x),
- Err(e) => Err(Error::BadRequest(format!(
- "{}: {}",
- reason.as_ref(),
- e.to_string()
- ))),
+ Err(e) => Err(Error::BadRequest(format!("{}: {}", reason.as_ref(), e))),
}
}
}