mirror of
https://github.com/Sheldan/abstracto-templates.git
synced 2026-03-24 13:44:38 +00:00
[AB-220] fixing starboard posts using embeds without description
using the thumbnail of such an embed as attachment to the post
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
<#list message.embeds>
|
||||
<@safe_include "starboard_post_embed_embeds_name"/>:
|
||||
<#items as embed>
|
||||
<@safe_include "starboard_post_embed_description"/>: ${embed.description?json_string} <#if embed.imageUrl?has_content> <@safe_include "starboard_post_embed_image_url"/>: ${embed.imageUrl} </#if>
|
||||
<#if embed.description??> <@safe_include "starboard_post_embed_description"/>: ${embed.description?json_string} </#if> <#if embed.imageUrl?has_content> <@safe_include "starboard_post_embed_image_url"/>: ${embed.imageUrl} </#if>
|
||||
</#items>
|
||||
</#list>
|
||||
",
|
||||
@@ -25,6 +25,9 @@
|
||||
<#if message.attachments?size gt 0>
|
||||
,"imageUrl": "${message.attachments[0].proxyUrl}"
|
||||
</#if>
|
||||
<#if message.attachments?size = 0 && message.embeds?size gt 0>
|
||||
,"imageUrl": "${message.embeds[0].cachedThumbnail.proxyUrl}"
|
||||
</#if>
|
||||
,"fields": [
|
||||
{
|
||||
"name": "<@safe_include "starboard_post_embed_original_field_title"/>"
|
||||
|
||||
Reference in New Issue
Block a user