forked from Deuxfleurs/garage
less strict ListBuckets (#178)
fix #175 Co-authored-by: Trinity Pointard <trinity.pointard@gmail.com> Reviewed-on: Deuxfleurs/garage#178 Co-authored-by: trinity-1686a <trinity.pointard@gmail.com> Co-committed-by: trinity-1686a <trinity.pointard@gmail.com>
This commit is contained in:
parent
1eb972b1ac
commit
ca7b438f3f
1 changed files with 1 additions and 5 deletions
|
@ -511,11 +511,7 @@ impl Endpoint {
|
||||||
let path = uri.path().trim_start_matches('/');
|
let path = uri.path().trim_start_matches('/');
|
||||||
let query = uri.query();
|
let query = uri.query();
|
||||||
if bucket.is_none() && path.is_empty() {
|
if bucket.is_none() && path.is_empty() {
|
||||||
if query.is_none() {
|
return Ok(Self::ListBuckets);
|
||||||
return Ok(Self::ListBuckets);
|
|
||||||
} else {
|
|
||||||
return Err(Error::BadRequest("Invalid ListBuckets query".to_owned()));
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
let (bucket, key) = if let Some(bucket) = bucket {
|
let (bucket, key) = if let Some(bucket) = bucket {
|
||||||
|
|
Loading…
Reference in a new issue