aboutsummaryrefslogtreecommitdiff
path: root/matrix/matrix.go
diff options
context:
space:
mode:
Diffstat (limited to 'matrix/matrix.go')
-rw-r--r--matrix/matrix.go8
1 files changed, 7 insertions, 1 deletions
diff --git a/matrix/matrix.go b/matrix/matrix.go
index 8cf2e96..4408ac5 100644
--- a/matrix/matrix.go
+++ b/matrix/matrix.go
@@ -768,7 +768,13 @@ func (c *Container) PrepareMarkdownMessage(roomID string, msgtype mautrix.Messag
return localEcho
}
-// SendMarkdownMessage sends a message with the given markdown text to the given room.
+func (c *Container) Redact(roomID, eventID, reason string) error {
+ defer debug.Recover()
+ _, err := c.client.RedactEvent(roomID, eventID, mautrix.ReqRedact{Reason: reason})
+ return err
+}
+
+// SendMessage sends the given event.
func (c *Container) SendEvent(event *event.Event) (string, error) {
defer debug.Recover()