Skip to content
Extraits de code Groupes Projets
Valider 0e77fcb0 rédigé par Vittorio Cuculo's avatar Vittorio Cuculo
Parcourir les fichiers

Fix #2488 soundcloud embedding

parent bbfb47b6
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -20,7 +20,7 @@ module OEmbedHelper ...@@ -20,7 +20,7 @@ module OEmbedHelper
else else
end end
return html.gsub('http', 'https').html_safe return html.gsub('http://', 'https://').html_safe
end end
def link_to_oembed_image(cache, prefix = 'thumbnail_') def link_to_oembed_image(cache, prefix = 'thumbnail_')
......
...@@ -109,7 +109,7 @@ describe OEmbedHelper do ...@@ -109,7 +109,7 @@ describe OEmbedHelper do
real_data = data['oembed_data'] real_data = data['oembed_data']
cache = OEmbedCache.new(:url => data['link_url']) cache = OEmbedCache.new(:url => data['link_url'])
cache.data = real_data cache.data = real_data
formatted = o_embed_html(cache).gsub('https', 'http') formatted = o_embed_html(cache).gsub('https://', 'http://')
case type case type
when 'photo' when 'photo'
formatted.should =~ /#{data['oembed_data']['url']}/ formatted.should =~ /#{data['oembed_data']['url']}/
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter