diff --git a/src/app/chat/page.tsx b/src/app/chat/page.tsx index 7724db2..ae4aba9 100644 --- a/src/app/chat/page.tsx +++ b/src/app/chat/page.tsx @@ -339,7 +339,8 @@ export default function Home() { } return x; })); - socket.emit('SIG_CHAT_CHGCHANNEL', { channel: data[0].name }, chgchannelChatRes); + if (whoami.id != null) + socket.emit('SIG_CHAT_CHGCHANNEL', { channel: data[0].name }, chgchannelChatRes); } }