diff --git a/opentech/storage_backends.py b/opentech/storage_backends.py index 2acf70c958d34c4c682f33f0e22b363f285ff525..82b84f92e8841537b8435b66a47f73a51e4c22bb 100644 --- a/opentech/storage_backends.py +++ b/opentech/storage_backends.py @@ -35,7 +35,7 @@ class PrivateMediaStorage(S3Boto3Storage): if hasattr(settings, 'AWS_PRIVATE_CUSTOM_DOMAIN'): # Django storage doesn't handle custom domains with auth strings custom_domain = settings.AWS_PRIVATE_CUSTOM_DOMAIN - parts = list(url.split(url)) + parts = list(parse.urlsplit(url)) parts[0:3] = self.url_protocol, custom_domain, filepath_to_uri(name) return parse.urlunsplit(parts)