Skip to content

Commit

Permalink
Returning absolute url from azure storage
Browse files Browse the repository at this point in the history
Using MEDIA_URL from settings as newer versions of django
default storage does.
  • Loading branch information
erlingbo committed Apr 19, 2015
1 parent 77d133c commit 277c6d1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion storages/backends/azure_storage.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,4 +73,4 @@ def _save(self, name, content):
return name

def url(self, name):
return "%s/%s" % (self.azure_bucket, name)
return "{}{}/{}".format(setting('MEDIA_URL'), self.azure_container, name)

0 comments on commit 277c6d1

Please sign in to comment.