mirror of
https://github.com/deuxfleurs-org/garage.git
synced 2026-08-06 04:47:42 +00:00
fix things up
This commit is contained in:
+4
-4
@@ -2,14 +2,14 @@ use err_derive::Error;
|
||||
use hyper::header::HeaderValue;
|
||||
use hyper::{HeaderMap, StatusCode};
|
||||
|
||||
use garage_api::generic_server::ApiError;
|
||||
use garage_api_common::generic_server::ApiError;
|
||||
|
||||
/// Errors of this crate
|
||||
#[derive(Debug, Error)]
|
||||
pub enum Error {
|
||||
/// An error received from the API crate
|
||||
#[error(display = "API error: {}", _0)]
|
||||
ApiError(garage_api::s3::error::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::s3::error::Error: From<T>,
|
||||
garage_api_s3::error::Error: From<T>,
|
||||
{
|
||||
fn from(err: T) -> Self {
|
||||
Error::ApiError(garage_api::s3::error::Error::from(err))
|
||||
Error::ApiError(garage_api_s3::error::Error::from(err))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -20,13 +20,13 @@ use opentelemetry::{
|
||||
|
||||
use crate::error::*;
|
||||
|
||||
use garage_api::generic_server::{server_loop, UnixListenerOn};
|
||||
use garage_api::helpers::*;
|
||||
use garage_api::s3::cors::{add_cors_headers, find_matching_cors_rule, handle_options_for_bucket};
|
||||
use garage_api::s3::error::{
|
||||
use garage_api_common::generic_server::{server_loop, UnixListenerOn};
|
||||
use garage_api_common::helpers::*;
|
||||
use garage_api_s3::cors::{add_cors_headers, find_matching_cors_rule, handle_options_for_bucket};
|
||||
use garage_api_s3::error::{
|
||||
CommonErrorDerivative, Error as ApiError, OkOrBadRequest, OkOrInternalError,
|
||||
};
|
||||
use garage_api::s3::get::{handle_get_without_ctx, handle_head_without_ctx};
|
||||
use garage_api_s3::get::{handle_get_without_ctx, handle_head_without_ctx};
|
||||
|
||||
use garage_model::garage::Garage;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user