Ensure GIFs are redirected to the original or they become static.

This commit is contained in:
Mark Felder 2020-08-26 16:18:11 -05:00
parent 2c95533ead
commit eead2276e7
1 changed files with 6 additions and 0 deletions

View File

@ -65,6 +65,12 @@ defmodule Pleroma.Web.MediaProxy.MediaProxyController do
end
end
defp handle_preview("image/gif" = _content_type, conn, url) do
mediaproxy_url = url |> MediaProxy.url()
redirect(conn, external: mediaproxy_url)
end
defp handle_preview("image/" <> _ = _content_type, conn, url) do
handle_image_preview(conn, url)
end