You've already forked matrix-js-sdk
mirror of
https://github.com/matrix-org/matrix-js-sdk.git
synced 2025-11-26 17:03:12 +03:00
Encode event IDs when redacting events
Because v3 rooms are a thing.
This commit is contained in:
@@ -1887,8 +1887,10 @@ function _sendEventHttpRequest(client, event) {
|
|||||||
}
|
}
|
||||||
path = utils.encodeUri(pathTemplate, pathParams);
|
path = utils.encodeUri(pathTemplate, pathParams);
|
||||||
} else if (event.getType() === "m.room.redaction") {
|
} else if (event.getType() === "m.room.redaction") {
|
||||||
const pathTemplate = `/rooms/$roomId/redact/${event.event.redacts}/$txnId`;
|
const pathTemplate = `/rooms/$roomId/redact/$redactsEventId/$txnId`;
|
||||||
path = utils.encodeUri(pathTemplate, pathParams);
|
path = utils.encodeUri(pathTemplate, Object.assign({
|
||||||
|
$redactsEventId: event.event.redacts,
|
||||||
|
}, pathParams));
|
||||||
} else {
|
} else {
|
||||||
path = utils.encodeUri(
|
path = utils.encodeUri(
|
||||||
"/rooms/$roomId/send/$eventType/$txnId", pathParams,
|
"/rooms/$roomId/send/$eventType/$txnId", pathParams,
|
||||||
|
|||||||
Reference in New Issue
Block a user