Rename Result.Resp to Result.Body.
diff --git a/openstack/objectstorage/v1/objects/requests.go b/openstack/objectstorage/v1/objects/requests.go
index c97b4fe..be4d107 100644
--- a/openstack/objectstorage/v1/objects/requests.go
+++ b/openstack/objectstorage/v1/objects/requests.go
@@ -131,9 +131,7 @@
})
defer resp.HttpResponse.Body.Close()
body, err := ioutil.ReadAll(resp.HttpResponse.Body)
- res.Resp = map[string]interface{}{
- "body": body,
- }
+ res.Body = body
res.Err = err
res.Headers = resp.HttpResponse.Header
return res
diff --git a/openstack/objectstorage/v1/objects/results.go b/openstack/objectstorage/v1/objects/results.go
index cc3a8ed..7bd2861 100644
--- a/openstack/objectstorage/v1/objects/results.go
+++ b/openstack/objectstorage/v1/objects/results.go
@@ -107,7 +107,7 @@
if dr.Err != nil {
return nil, dr.Err
}
- return dr.Resp["body"].([]byte), nil
+ return dr.Body.([]byte), nil
}
// GetResult is a *http.Response that is returned from a call to the Get function.