lib/onebox/engine/audio_onebox.rb in onebox-1.3.0 vs lib/onebox/engine/audio_onebox.rb in onebox-1.3.1

- old
+ new

@@ -1,15 +1,13 @@ module Onebox module Engine - class VideoOnebox + class AudioOnebox include Engine - matches_regexp /^https?:\/\/.*\.mp3$/ + matches_regexp /^(https?:)?\/\/.*\.(mp3|ogg|wav)(\?.*)?$/ def to_html "<audio controls><source src='#{@url}'><a href='#{@url}'>#{@url}</a></audio>" end end end end - -