1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2026-01-03 23:22:30 +03:00

Merge pull request #922 from matrix-org/bwindels/editedmarker

Add method to retrieve replacing event
This commit is contained in:
Bruno Windels
2019-05-17 11:04:00 +00:00
committed by GitHub

View File

@@ -825,6 +825,15 @@ utils.extend(module.exports.MatrixEvent.prototype, {
return this._replacingEvent && this._replacingEvent.getId();
},
/**
* Returns the event replacing the content of this event, if any.
*
* @return {MatrixEvent?}
*/
replacingEvent() {
return this._replacingEvent;
},
/**
* Summarise the event as JSON for debugging. If encrypted, include both the
* decrypted and encrypted view of the event. This is named `toJSON` for use