From 186938d32aea127e60ae1c7279836998849b8bfe Mon Sep 17 00:00:00 2001 From: Kegan Dougal Date: Thu, 19 Jan 2023 11:02:43 +0000 Subject: [PATCH] prettier --- src/SlidingSyncManager.ts | 8 +++++++- src/hooks/useSlidingSyncRoomSearch.ts | 4 +++- src/stores/room-list/SlidingRoomListStore.ts | 6 +----- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/SlidingSyncManager.ts b/src/SlidingSyncManager.ts index 7f47e41728..0f67962681 100644 --- a/src/SlidingSyncManager.ts +++ b/src/SlidingSyncManager.ts @@ -137,7 +137,13 @@ export class SlidingSyncManager { this.listIdToIndex = {}; // by default use the encrypted subscription as that gets everything, which is a safer // default than potentially missing member events. - this.slidingSync = new SlidingSync(proxyUrl, new Map(), ENCRYPTED_SUBSCRIPTION, client, SLIDING_SYNC_TIMEOUT_MS); + this.slidingSync = new SlidingSync( + proxyUrl, + new Map(), + ENCRYPTED_SUBSCRIPTION, + client, + SLIDING_SYNC_TIMEOUT_MS, + ); this.slidingSync.addCustomSubscription(UNENCRYPTED_SUBSCRIPTION_NAME, UNENCRYPTED_SUBSCRIPTION); // set the space list this.slidingSync.setList(SlidingSyncManager.ListSpaces, { diff --git a/src/hooks/useSlidingSyncRoomSearch.ts b/src/hooks/useSlidingSyncRoomSearch.ts index c029d8c21b..00f26c198b 100644 --- a/src/hooks/useSlidingSyncRoomSearch.ts +++ b/src/hooks/useSlidingSyncRoomSearch.ts @@ -56,7 +56,9 @@ export const useSlidingSyncRoomSearch = (): { }, }); const rooms = []; - const { roomIndexToRoomId } = SlidingSyncManager.instance.slidingSync.getListData(SlidingSyncManager.ListSearch); + const { roomIndexToRoomId } = SlidingSyncManager.instance.slidingSync.getListData( + SlidingSyncManager.ListSearch, + ); let i = 0; while (roomIndexToRoomId[i]) { const roomId = roomIndexToRoomId[i]; diff --git a/src/stores/room-list/SlidingRoomListStore.ts b/src/stores/room-list/SlidingRoomListStore.ts index b54dd3913d..eeacab35f6 100644 --- a/src/stores/room-list/SlidingRoomListStore.ts +++ b/src/stores/room-list/SlidingRoomListStore.ts @@ -256,11 +256,7 @@ export class SlidingRoomListStoreClass extends AsyncStoreWithClient impl this.tagMap = tagMap; } - private onSlidingSyncListUpdate( - tagId: string, - joinCount: number, - roomIndexToRoomId: Record, - ): void { + private onSlidingSyncListUpdate(tagId: string, joinCount: number, roomIndexToRoomId: Record): void { this.counts[tagId] = joinCount; this.refreshOrderedLists(tagId, roomIndexToRoomId); // let the UI update