Skip to content
Browse files

Include OEmbed provider name in embed DIVs.

  • Loading branch information...
1 parent 5ab6a97 commit d6cc5366dc80517178d9bc6a88b83f593028b58b @hmans committed Mar 3, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 lib/schnitzelpress/markdown_renderer.rb
View
2 lib/schnitzelpress/markdown_renderer.rb
@@ -8,7 +8,7 @@ def block_code(code, language)
def image(link, title, alt_text)
oembed = OEmbed::Providers.get(link)
- %q(<div class="embedded %s">%s</div>) % [oembed.type, oembed.html]
+ %q(<div class="embedded %s %s">%s</div>) % [oembed.type, oembed.provider_name.parameterize, oembed.html]
rescue OEmbed::NotFound
%q(<img src="%s" title="%s" alt="%s"/>) % [link, escape_html(title), escape_html(alt_text)]
end

0 comments on commit d6cc536

Please sign in to comment.
Something went wrong with that request. Please try again.