From 8d645b07df5b37562118c7f1c006916d80a7544c Mon Sep 17 00:00:00 2001 From: Puyodead1 Date: Mon, 20 Nov 2023 10:25:33 -0500 Subject: [PATCH] fix some errors about keys --- src/components/ListSection.tsx | 4 ++-- src/components/MemberList/MemberList.tsx | 3 ++- src/stores/GatewayConnectionStore.ts | 7 ++++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/src/components/ListSection.tsx b/src/components/ListSection.tsx index c5189b0..0d362cb 100644 --- a/src/components/ListSection.tsx +++ b/src/components/ListSection.tsx @@ -49,8 +49,8 @@ function ListSection(props: Props) { {props.name} - {props.items.map((item) => ( - {item} + {props.items.map((item, i) => ( + {item} ))} diff --git a/src/components/MemberList/MemberList.tsx b/src/components/MemberList/MemberList.tsx index 3f48e12..2235a3f 100644 --- a/src/components/MemberList/MemberList.tsx +++ b/src/components/MemberList/MemberList.tsx @@ -57,8 +57,9 @@ function MemberList() { {list - ? list.map((category) => ( + ? list.map((category, i) => ( x.nick ?? x.user?.username).filter((x) => x) as string[] diff --git a/src/stores/GatewayConnectionStore.ts b/src/stores/GatewayConnectionStore.ts index ca77e85..87c8304 100644 --- a/src/stores/GatewayConnectionStore.ts +++ b/src/stores/GatewayConnectionStore.ts @@ -469,6 +469,7 @@ export default class GatewayConnectionStore { } } + this.reconnectTimeout = 0; this.app.setGatewayReady(true); }; @@ -478,9 +479,9 @@ export default class GatewayConnectionStore { if (guildChannels.includes(channelId)) return; const payload: GatewayLazyRequestData = { guild_id: guildId, - activities: true, - threads: true, - typing: true, + // activities: true, + // threads: true, + // typing: true, channels: { [channelId]: [[0, 99]], },