FIX: use upload's cdn url in composer preview if available.

This commit is contained in:
Vinoth Kannan 2019-10-14 08:47:15 +05:30
parent 2b74dc5885
commit e4fe864c0b

View File

@ -70,7 +70,7 @@ module PrettyText
if short_urls = reverse_map[sha1]
short_urls.each do |short_url|
result[short_url] = {
url: url,
url: Discourse.store.cdn_url(url),
short_path: Upload.short_path(sha1: sha1, extension: extension),
base62_sha1: Upload.base62_sha1(sha1)
}