Skip to content

Commit

Permalink
HTTPFile has 'content_type' property. Allows HTTPDownloadView to prox…
Browse files Browse the repository at this point in the history
…y Content-Type header. Refs #116
  • Loading branch information
benoitbryon committed Mar 14, 2016
1 parent 18fd9ab commit 5621426
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions django_downloadview/files.py
Expand Up @@ -256,3 +256,8 @@ def size(self):
"""
return self.request.headers['Content-Length']

@property
def content_type(self):
"""Return content type of the file (from original response)."""
return self.request.headers['Content-Type']

0 comments on commit 5621426

Please sign in to comment.