From 49632b3bab05ae56f7fa3227a2e67a94ba27de6c Mon Sep 17 00:00:00 2001 From: MathMan05 Date: Wed, 14 May 2025 19:06:56 -0500 Subject: [PATCH] some fixes --- src/webpage/guild.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/webpage/guild.ts b/src/webpage/guild.ts index 4277cb8..87c756d 100644 --- a/src/webpage/guild.ts +++ b/src/webpage/guild.ts @@ -1429,7 +1429,7 @@ class Guild extends SnowFlake { return; } } - if (this.prevchannel && ID !== null) { + if (this.prevchannel && ID !== null && this.prevchannel.visable) { console.log(this.prevchannel); this.prevchannel.getHTML(addstate); return; @@ -1467,6 +1467,12 @@ class Guild extends SnowFlake { (document.getElementById("sideDiv") as HTMLElement).innerHTML = ""; } noChannel(addstate: boolean) { + for (const c of this.channels) { + if (c.visable) { + this.loadChannel(c.id, addstate); + return; + } + } if (addstate) { history.pushState([this.id, undefined], "", "/channels/" + this.id); }