Store preview image for embedded photo in preview cards (#5986)
The preview image would be useful to embed in timeline.pull/5961/merge
parent
2a61b9f000
commit
f9f6918148
|
@ -89,6 +89,7 @@ class FetchLinkCardService < BaseService
|
||||||
when 'photo'
|
when 'photo'
|
||||||
return false unless response.respond_to?(:url)
|
return false unless response.respond_to?(:url)
|
||||||
@card.embed_url = response.url
|
@card.embed_url = response.url
|
||||||
|
@card.image = URI.parse(response.url)
|
||||||
@card.width = response.width.presence || 0
|
@card.width = response.width.presence || 0
|
||||||
@card.height = response.height.presence || 0
|
@card.height = response.height.presence || 0
|
||||||
when 'video'
|
when 'video'
|
||||||
|
|
Loading…
Reference in New Issue