From d4ed9e816ba6fa0820f005276744c5996cefad07 Mon Sep 17 00:00:00 2001 From: Luke Barnard Date: Thu, 16 Mar 2017 17:00:10 +0000 Subject: [PATCH] Display timestamps and profiles for redacted events This is part of fixing https://github.com/vector-im/riot-web/issues/3390 --- src/components/structures/MessagePanel.js | 2 +- src/components/views/rooms/EventTile.js | 9 +++------ 2 files changed, 4 insertions(+), 7 deletions(-) diff --git a/src/components/structures/MessagePanel.js b/src/components/structures/MessagePanel.js index ff507b6f90..0f8d35f525 100644 --- a/src/components/structures/MessagePanel.js +++ b/src/components/structures/MessagePanel.js @@ -413,7 +413,7 @@ module.exports = React.createClass({ var continuation = false; if (prevEvent !== null - && !prevEvent.isRedacted() && prevEvent.sender && mxEv.sender + && prevEvent.sender && mxEv.sender && mxEv.sender.userId === prevEvent.sender.userId && mxEv.getType() == prevEvent.getType()) { continuation = true; diff --git a/src/components/views/rooms/EventTile.js b/src/components/views/rooms/EventTile.js index 48f0f282c1..b451d1c046 100644 --- a/src/components/views/rooms/EventTile.js +++ b/src/components/views/rooms/EventTile.js @@ -435,10 +435,7 @@ module.exports = WithMatrixClient(React.createClass({ let avatarSize; let needsSenderProfile; - if (isRedacted) { - avatarSize = 0; - needsSenderProfile = false; - } else if (this.props.tileShape === "notif") { + if (this.props.tileShape === "notif") { avatarSize = 24; needsSenderProfile = true; } else if (isInfoMessage) { @@ -503,8 +500,8 @@ module.exports = WithMatrixClient(React.createClass({ else if (e2eEnabled) { e2e = ; } - const timestamp = this.props.mxEvent.isRedacted() ? - null : ; + const timestamp = this.props.mxEvent.getTs() ? + : null; if (this.props.tileShape === "notif") { var room = this.props.matrixClient.getRoom(this.props.mxEvent.getRoomId());