refactor errors / isolate core/http errors

This commit is contained in:
mpostma 2020-05-22 12:03:57 +02:00
parent e2db197b3f
commit d69180ec67
29 changed files with 585 additions and 480 deletions

View file

@ -1,6 +1,7 @@
use std::{error, fmt};
use meilisearch_error::{ErrorCode, Code};
pub type SResult<T> = Result<T, Error>;
#[derive(Debug)]
@ -22,3 +23,9 @@ impl fmt::Display for Error {
}
impl error::Error for Error {}
impl ErrorCode for Error {
fn error_code(&self) -> Code {
unimplemented!()
}
}