rely on preview urls if available for gallery

This commit is contained in:
Albert Yi
2018-09-11 14:57:18 -07:00
parent e0e85a3139
commit 4972c998f8
8 changed files with 42 additions and 2 deletions

View File

@@ -53,6 +53,16 @@ module Sources
image_urls.first
end
# A smaller representation of the image that's suitable for
# displaying previews.
def preview_urls
image_urls
end
def preview_url
preview_urls.first
end
# Whatever <tt>url</tt> is, this method should return a link to the HTML
# page containing the resource. It should not be a binary file. It will
# eventually be assigned as the source for the post, but it does not