simplify success response for GetObjectAttributes() (#18746)

This commit is contained in:
Harshavardhana 2024-01-05 12:50:07 -08:00 committed by GitHub
parent 9b8ba97f9f
commit 42dc6329e6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -813,17 +813,7 @@ func (api objectAPIHandlers) getObjectAttributesHandler(ctx context.Context, obj
}
}
outBytes, err := xml.Marshal(OA)
if err != nil {
writeErrorResponseHeadersOnly(w, toAPIError(ctx, err))
}
writeResponse(
w,
200,
append([]byte(`<?xml version="1.0" encoding="UTF-8"?>`), outBytes...),
mimeXML,
)
writeSuccessResponseXML(w, encodeResponse(OA))
sendEvent(eventArgs{
EventName: event.ObjectAccessedAttributes,