From f2dccbc9f7bc58ee46609c31650d3f18af6cde28 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Thu, 12 Aug 2021 09:38:57 +0200 Subject: [PATCH] Use function syntax MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Šimon Brandner --- .../room-list/algorithms/tag-sorting/RecentAlgorithm.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/stores/room-list/algorithms/tag-sorting/RecentAlgorithm.ts b/src/stores/room-list/algorithms/tag-sorting/RecentAlgorithm.ts index 539cfde726..5ddfd96c8a 100644 --- a/src/stores/room-list/algorithms/tag-sorting/RecentAlgorithm.ts +++ b/src/stores/room-list/algorithms/tag-sorting/RecentAlgorithm.ts @@ -23,7 +23,7 @@ import { EffectiveMembership, getEffectiveMembership } from "../../../../utils/m import { EventType } from "matrix-js-sdk/src/@types/event"; import { MatrixEvent } from "matrix-js-sdk/src/models/event"; -const ignoreSelfEvent = (event: MatrixEvent): boolean => { +export function ignoreSelfEvent(event: MatrixEvent): boolean { const type = event.getType(); const content = event.getContent(); const prevContent = event.getPrevContent(); @@ -38,7 +38,7 @@ const ignoreSelfEvent = (event: MatrixEvent): boolean => { if (type === EventType.RoomMember && prevContent.displayname !== content.displayname) return true; return false; -}; +} export const sortRooms = (rooms: Room[]): Room[] => { // We cache the timestamp lookup to avoid iterating forever on the timeline