fix: avoid sending errors on missing objects on locked buckets (#10994)

make sure multi-object delete returned errors that are AWS S3 compatible
This commit is contained in:
Harshavardhana
2020-11-28 21:15:45 -08:00
committed by GitHub
parent e6fa410778
commit bdd094bc39
16 changed files with 114 additions and 61 deletions

View File

@@ -93,7 +93,7 @@ func getOpts(ctx context.Context, r *http.Request, bucket, object string) (Objec
_, err := uuid.Parse(vid)
if err != nil {
logger.LogIf(ctx, err)
return opts, VersionNotFound{
return opts, InvalidVersionID{
Bucket: bucket,
Object: object,
VersionID: vid,
@@ -209,7 +209,7 @@ func putOpts(ctx context.Context, r *http.Request, bucket, object string, metada
_, err := uuid.Parse(vid)
if err != nil {
logger.LogIf(ctx, err)
return opts, VersionNotFound{
return opts, InvalidVersionID{
Bucket: bucket,
Object: object,
VersionID: vid,