Add safety check

This commit is contained in:
MathMan05 2024-08-18 11:13:54 -05:00
parent fa1db8cf5d
commit 7f80a528ba
2 changed files with 6 additions and 0 deletions

View file

@ -798,6 +798,9 @@ class Channel {
return;
this.infinitefocus = true;
const messages = document.getElementById("channelw");
for (const thing of messages.getElementsByClassName("messagecontainer")) {
thing.remove();
}
const loading = document.getElementById("loadingdiv");
const removetitle = document.getElementById("removetitle");
//messages.innerHTML="";

View file

@ -802,6 +802,9 @@ class Channel{
if(this.infinitefocus) return;
this.infinitefocus=true;
const messages=document.getElementById("channelw");
for(const thing of messages.getElementsByClassName("messagecontainer")){
thing.remove();
}
const loading=document.getElementById("loadingdiv");
const removetitle=document.getElementById("removetitle");
//messages.innerHTML="";