diff --git a/format/markdown.go b/format/markdown.go index bd29cec3..95bba76d 100644 --- a/format/markdown.go +++ b/format/markdown.go @@ -56,7 +56,7 @@ func RenderMarkdown(text string, allowMarkdown, allowHTML bool) event.MessageEve htmlBody = strings.Replace(text, "\n", "
", -1) } - if len(htmlBody) > 0 { + if len(htmlBody) > 0 && (allowMarkdown || allowHTML) { text = HTMLToText(htmlBody) if htmlBody != text { diff --git a/version.go b/version.go index 9aca2ef7..b8c04937 100644 --- a/version.go +++ b/version.go @@ -1,5 +1,5 @@ package mautrix -const Version = "v0.9.9" +const Version = "v0.9.10" var DefaultUserAgent = "mautrix-go/" + Version