lib/onebox/engine/google_drive_onebox.rb in onebox-2.2.12 vs lib/onebox/engine/google_drive_onebox.rb in onebox-2.2.13

- old
+ new

@@ -5,26 +5,26 @@ class GoogleDriveOnebox include Engine include StandardEmbed include LayoutSupport - matches_regexp /^(https?:)?\/\/(drive\.google\.com)\/file\/d\/(?<key>[\w-]*)\/.+$/ + matches_regexp(/^(https?:)?\/\/(drive\.google\.com)\/file\/d\/(?<key>[\w-]*)\/.+$/) always_https protected def data og_data = get_opengraph title = og_data.title || "Google Drive" title = "#{og_data.title} (video)" if og_data.type =~ /^video[\/\.]/ description = og_data.description || "Google Drive file." - result = { link: link, - title: title, - description: Onebox::Helpers.truncate(description, 250), - image: og_data.image - } - result + { + link: link, + title: title, + description: Onebox::Helpers.truncate(description, 250), + image: og_data.image + } end end end end