diff options
author | Alex Auvolat <alex@adnab.me> | 2022-05-13 15:10:52 +0200 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2022-05-13 15:10:52 +0200 |
commit | f82b938033f1a01a136315b5f37ecb89b78bca0c (patch) | |
tree | aacba0081d4bd854f3d29a6b9d94202ef94b980d /src/web | |
parent | 96b11524d53b3616a28f33e2b057655be1639f6f (diff) | |
download | garage-f82b938033f1a01a136315b5f37ecb89b78bca0c.tar.gz garage-f82b938033f1a01a136315b5f37ecb89b78bca0c.zip |
Rename error::Error to s3::error::Error
Diffstat (limited to 'src/web')
-rw-r--r-- | src/web/error.rs | 6 | ||||
-rw-r--r-- | src/web/web_server.rs | 2 |
2 files changed, 4 insertions, 4 deletions
diff --git a/src/web/error.rs b/src/web/error.rs index 478731b5..bd8f17b5 100644 --- a/src/web/error.rs +++ b/src/web/error.rs @@ -9,7 +9,7 @@ use garage_api::generic_server::ApiError; pub enum Error { /// An error received from the API crate #[error(display = "API error: {}", _0)] - ApiError(garage_api::Error), + ApiError(garage_api::s3::error::Error), /// The file does not exist #[error(display = "Not found")] @@ -22,10 +22,10 @@ pub enum Error { impl<T> From<T> for Error where - garage_api::Error: From<T>, + garage_api::s3::error::Error: From<T>, { fn from(err: T) -> Self { - Error::ApiError(garage_api::Error::from(err)) + Error::ApiError(garage_api::s3::error::Error::from(err)) } } diff --git a/src/web/web_server.rs b/src/web/web_server.rs index e83bc4cb..dad98dfc 100644 --- a/src/web/web_server.rs +++ b/src/web/web_server.rs @@ -18,7 +18,7 @@ use opentelemetry::{ use crate::error::*; -use garage_api::error::{Error as ApiError, OkOrBadRequest, OkOrInternalError}; +use garage_api::s3::error::{Error as ApiError, OkOrBadRequest, OkOrInternalError}; use garage_api::helpers::{authority_to_host, host_to_bucket}; use garage_api::s3::cors::{add_cors_headers, find_matching_cors_rule, handle_options_for_bucket}; use garage_api::s3::get::{handle_get, handle_head}; |