http_security_plug.ex: Fix non-proxied media
authorHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Fri, 29 May 2020 15:17:02 +0000 (17:17 +0200)
committerHaelwenn (lanodan) Monnier <contact@hacktivis.me>
Fri, 29 May 2020 15:20:09 +0000 (17:20 +0200)
lib/pleroma/plugs/http_security_plug.ex

index 2208d1d6ce7c5127867fc5b363ef7bb6a470903f..4b926e867e02498cf0647f5d1ca7294d4a68a3a5 100644 (file)
@@ -75,7 +75,7 @@ defmodule Pleroma.Plugs.HTTPSecurityPlug do
         sources = get_proxy_and_attachment_sources()
         {[img_src, sources], [media_src, sources]}
       else
-        {img_src, media_src}
+        {img_src <> " https:", media_src <> " https:"}
       end
 
     connect_src = ["connect-src 'self' ", static_url, ?\s, websocket_url]