1
0
mirror of https://github.com/matrix-org/matrix-js-sdk.git synced 2025-08-19 16:42:09 +03:00

hopefully fix NPE that bit Antony

This commit is contained in:
Matthew Hodgson
2015-07-16 01:21:23 +01:00
parent b2f5d0b40a
commit ee4d0fb9ee

View File

@@ -136,6 +136,8 @@ module.exports = function(client) {
}
var room = client.getRoom(ev.room_id);
if (!room || !room.currentState || !room.currentState.members) { return false; }
var displayName = room.currentState.getMember(client.credentials.userId).name;
var pat = new RegExp("\\b" + escapeRegExp(displayName) + "\\b", 'i');