mirror of
https://github.com/hoernschen/dendrite.git
synced 2025-07-31 13:22:46 +00:00
parent
16d922de70
commit
05a8f1ede3
6 changed files with 38 additions and 7 deletions
|
@ -34,7 +34,8 @@ import (
|
|||
)
|
||||
|
||||
type redactionContent struct {
|
||||
Reason string `json:"reason"`
|
||||
Reason string `json:"reason"`
|
||||
Redacts string `json:"redacts"`
|
||||
}
|
||||
|
||||
type redactionResponse struct {
|
||||
|
@ -151,6 +152,11 @@ func SendRedaction(
|
|||
Type: spec.MRoomRedaction,
|
||||
Redacts: eventID,
|
||||
}
|
||||
|
||||
// Room version 11 expects the "redacts" field on the
|
||||
// content field, so add it here as well
|
||||
r.Redacts = eventID
|
||||
|
||||
err = proto.SetContent(r)
|
||||
if err != nil {
|
||||
util.GetLogger(req.Context()).WithError(err).Error("proto.SetContent failed")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue