Skip to content

Commit

Permalink
Don't override default ACL already configured on AWS side (tweak prev…
Browse files Browse the repository at this point in the history
…ious).
  • Loading branch information
jcushman committed Jul 18, 2018
1 parent 752c095 commit 9b62b73
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
3 changes: 2 additions & 1 deletion storages/backends/s3boto3.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,8 @@ def write(self, content):
self._is_dirty = True
if self._multipart is None:
parameters = self._storage.object_parameters.copy()
parameters['ACL'] = self._storage.default_acl
if self._storage.default_acl:
parameters['ACL'] = self._storage.default_acl
parameters['ContentType'] = (mimetypes.guess_type(self.obj.key)[0] or
self._storage.default_content_type)
if self._storage.reduced_redundancy:
Expand Down
1 change: 0 additions & 1 deletion tests/test_s3boto3.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ def test_content_type(self):
content.file,
ExtraArgs={
'ContentType': 'image/jpeg',
'ACL': self.storage.default_acl,
}
)

Expand Down

0 comments on commit 9b62b73

Please # to comment.