feat: auto-join #ops on first login (web + TUI)
New users with no peer/group set automatically join #ops so they have someone to talk to. Saved peer overrides this on subsequent visits. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -925,9 +925,20 @@ async function enterChat() {
|
||||
addSys('/alias · /g · /gleave · /gkick · /gmembers · /glist · /friend · /file · /info');
|
||||
|
||||
const savedPeer = localStorage.getItem('wz-peer');
|
||||
if (savedPeer) $peerInput.value = savedPeer;
|
||||
if (savedPeer) {
|
||||
$peerInput.value = savedPeer;
|
||||
}
|
||||
|
||||
connectWebSocket();
|
||||
|
||||
// Auto-join #ops if no peer/group set
|
||||
if (!savedPeer) {
|
||||
setTimeout(async () => {
|
||||
await groupSwitch('ops');
|
||||
addSys('Welcome! You have been added to #ops');
|
||||
}, 500);
|
||||
}
|
||||
|
||||
$input.focus();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user