mirror of
https://mau.dev/mautrix/go.git
synced 2026-03-14 14:25:53 +01:00
bridgev2/commands: implement MarkRead
This commit is contained in:
parent
826089e020
commit
cf801729af
1 changed files with 5 additions and 5 deletions
|
|
@ -10,6 +10,7 @@ import (
|
|||
"context"
|
||||
"fmt"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/rs/zerolog"
|
||||
|
||||
|
|
@ -92,9 +93,8 @@ func (ce *Event) Redact(req ...mautrix.ReqRedact) {
|
|||
|
||||
// MarkRead marks the command event as read.
|
||||
func (ce *Event) MarkRead() {
|
||||
// TODO
|
||||
//err := ce.Bot.SendReceipt(ce.Ctx, ce.RoomID, ce.EventID, event.ReceiptTypeRead, nil)
|
||||
//if err != nil {
|
||||
// ce.Log.Err(err).Msg("Failed to mark command as read")
|
||||
//}
|
||||
err := ce.Bot.MarkRead(ce.Ctx, ce.RoomID, ce.EventID, time.Now())
|
||||
if err != nil {
|
||||
ce.Log.Err(err).Msg("Failed to mark command as read")
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue