From b6182f7e6c73e375c16cb5b33a4e982e5acd8dbf Mon Sep 17 00:00:00 2001
From: Michael Telatynski <7t3chguy@gmail.com>
Date: Sun, 10 Dec 2017 12:54:19 +0000
Subject: [PATCH] Tidy Quote class, removing comments etc
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
---
src/components/views/elements/Quote.js | 34 +++++---------------------
1 file changed, 6 insertions(+), 28 deletions(-)
diff --git a/src/components/views/elements/Quote.js b/src/components/views/elements/Quote.js
index 1925cfbd65..c7f785f2cf 100644
--- a/src/components/views/elements/Quote.js
+++ b/src/components/views/elements/Quote.js
@@ -15,14 +15,8 @@ limitations under the License.
*/
import React from 'react';
import sdk from '../../../index';
-import dis from '../../../dispatcher';
-import classNames from 'classnames';
-import { Room, RoomMember } from 'matrix-js-sdk';
import PropTypes from 'prop-types';
import MatrixClientPeg from '../../../MatrixClientPeg';
-import { getDisplayAliasForRoom } from '../../../Rooms';
-import {makeUserPermalink} from "../../../matrix-to";
-import DateUtils from "../../../DateUtils";
// For URLs of matrix.to links in the timeline which have been reformatted by
// HttpUtils transformTags to relative links. This excludes event URLs (with `[^\/]*`)
@@ -87,14 +81,9 @@ const Quote = React.createClass({
},
componentWillMount() {
- this._unmounted = false;
this.componentWillReceiveProps(this.props);
},
- componentWillUnmount() {
- this._unmounted = true;
- },
-
async getEvent(room, eventId) {
let event = room.findEventById(eventId);
if (event) {
@@ -111,27 +100,16 @@ const Quote = React.createClass({
const ev = this.state.event;
if (ev) {
const EventTile = sdk.getComponent('views.rooms.EventTile');
- // const EmojiText = sdk.getComponent('views.elements.EmojiText');
- // const Pill = sdk.getComponent('views.elements.Pill');
- // const senderUrl = makeUserPermalink(ev.getSender());
- // const EventTileType = sdk.getComponent(EventTile.getHandlerTile(ev));
- /*return */
return
- {/**/}
- {/*
;
- /*;*/
- } else {
- // Deliberately render nothing if the URL isn't recognised
- return