Fix attachments not getting placeholders replaced

This commit is contained in:
Vankka 2023-05-30 23:46:22 +03:00
parent 4613e821e2
commit c7466202b9
No known key found for this signature in database
GPG Key ID: 6E50CB7A29B96AD0

View File

@ -335,6 +335,7 @@ public class ReceivedDiscordMessageImpl implements ReceivedDiscordMessage {
for (Attachment attachment : attachments) { for (Attachment attachment : attachments) {
components.add(ComponentUtil.fromAPI( components.add(ComponentUtil.fromAPI(
discordSRV.componentFactory().textBuilder(attachmentFormat) discordSRV.componentFactory().textBuilder(attachmentFormat)
.applyPlaceholderService()
.addPlaceholder("file_name", attachment.fileName()) .addPlaceholder("file_name", attachment.fileName())
.addPlaceholder("file_url", attachment.url()) .addPlaceholder("file_url", attachment.url())
.build() .build()