You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-12-05 17:02:07 +03:00
Update relation collections after redaction
This watches for redactions of relations and updates the relations collection to match, including various aggregations. In addition, a redaction event is emitted on the redaction collection to notify consumers of the change. Part of https://github.com/vector-im/riot-web/issues/9574 Part of https://github.com/vector-im/riot-web/issues/9485
This commit is contained in:
@@ -1011,6 +1011,7 @@ Room.prototype._addLiveEvent = function(event, duplicateStrategy) {
|
||||
// if we know about this event, redact its contents now.
|
||||
const redactedEvent = this.getUnfilteredTimelineSet().findEventById(redactId);
|
||||
if (redactedEvent) {
|
||||
this.emit("Room.beforeRedaction", redactedEvent, event, this);
|
||||
redactedEvent.makeRedacted(event);
|
||||
this.emit("Room.redaction", event, this);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user