David Larlet  committed a26c3c7

Fix a couple of bugs spoted by Ariel in S3 storages

  • Participants
  • Parent commits c8c088b
  • Branches default

Comments (0)

Files changed (2)

File backends/

+AWS_BUCKET_PREFIX = getattr(settings, AWS_BUCKET_NAME, {})
     from boto.s3.connection import S3Connection
 class S3BotoStorage(Storage):
     """Amazon Simple Storage Service using Boto"""
-    def __init__(self, bucket="root", bucketprefix=settings.AWS_BUCKET_PREFIX, access_key=None, secret_key=None, acl='public-read'):
+    def __init__(self, bucket="root", bucketprefix=AWS_BUCKET_PREFIX, access_key=None, secret_key=None, acl='public-read'):
         self.acl = acl
         if not access_key and not secret_key:

File backends/

             headers = {'Range': 'bytes=%s-%s' % (start_range, end_range)}
         response = self.connection.get(self.bucket, name, headers)
         headers = response.http_response.msg
-        return, headers['etag'], headers.get('content-range', None)
+        return, headers.get('etag', None), headers.get('content-range', None)
     def _save(self, name, content):