Add blurhash to preview cards (#13984)

Fixes #13001
This commit is contained in:
ThibG
2020-06-05 23:10:41 +02:00
committed by GitHub
parent a415f44fd1
commit 346d9b3d2e
5 changed files with 17 additions and 5 deletions

View File

@ -6,7 +6,7 @@ class REST::PreviewCardSerializer < ActiveModel::Serializer
attributes :url, :title, :description, :type,
:author_name, :author_url, :provider_name,
:provider_url, :html, :width, :height,
:image, :embed_url
:image, :embed_url, :blurhash
def image
object.image? ? full_asset_url(object.image.url(:original)) : nil