Don't count as an unread message if we don't have a tile for it.

This commit is contained in:
David Baker 2016-01-25 17:13:07 +00:00
parent c1f28bb6b9
commit f8cc6bdad6

View file

@ -15,6 +15,7 @@ limitations under the License.
*/
var MatrixClientPeg = require('./MatrixClientPeg');
var sdk = require('./index');
module.exports = {
/**
@ -27,7 +28,8 @@ module.exports = {
} else if (ev.getType == 'm.room.message' && ev.getContent().msgtype == 'm.notify') {
return false;
}
return true;
var EventTile = sdk.getComponent('rooms.EventTile');
return EventTile.haveTileForEvent(ev);
},
doesRoomHaveUnreadMessages: function(room) {