Skip to content

Commit

Permalink
revert changes
Browse files Browse the repository at this point in the history
  • Loading branch information
kelvin-muchiri committed Oct 1, 2024
1 parent 51943e9 commit 554d3fa
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions onadata/apps/viewer/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -894,9 +894,7 @@ def attachment_url(request, size="medium"):

return response
if not attachment.mimetype.startswith("image"):
return generate_media_download_url(
attachment.media_file.name, attachment.mimetype
)
return generate_media_download_url(attachment)
media_url = image_url(attachment, size)
if media_url:
return redirect(media_url)
Expand Down

0 comments on commit 554d3fa

Please sign in to comment.