From 33e9b0d000f4abbd310423fdd89ee12c885dc440 Mon Sep 17 00:00:00 2001 From: Malte E <97891689+maltee1@users.noreply.github.com> Date: Tue, 26 Dec 2023 20:07:42 +0100 Subject: [PATCH] Update portal.go Co-authored-by: Tulir Asokan --- portal.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/portal.go b/portal.go index d4955d0c..7bacd211 100644 --- a/portal.go +++ b/portal.go @@ -1877,6 +1877,9 @@ func (portal *Portal) addRelaybotFormat(userID id.UserID, content *event.Message if member == nil { member = &event.MemberEventContent{} } + if content.FileName == "" { + content.FileName = content.Body + } content.EnsureHasHTML() data, err := portal.bridge.Config.Bridge.Relay.FormatMessage(content, userID, *member) if err != nil {