diff --git a/sshChat.js b/sshChat.js index 196803e..3bdd337 100644 --- a/sshChat.js +++ b/sshChat.js @@ -254,12 +254,7 @@ async function handleCommand(input) { } else { console.log(`${USERNAME}: ${input}`) } - - } - - - } swarm.on('connection', conn => { @@ -317,7 +312,6 @@ swarm.on('error', (err) => { console.log('Error connecting to peer:', err); }); - // Join a common topic const topic = process.argv[2] ? b4a.from(process.argv[2], 'hex') : crypto.randomBytes(32) @@ -338,15 +332,11 @@ setTimeout(() => { }) }, 1000); - - - // Append the boxes to the screen screen.append(mainBox); screen.append(stdinBox); screen.append(sidebarBox); - // Handle input in the stdinBox stdinBox.on('submit', (input) => { // handle the input here @@ -354,13 +344,8 @@ stdinBox.on('submit', (input) => { handleCommand(input); // clear the input field stdinBox.focus(); - - // screen.render(); }); -// setInterval(() => { -// mainBox.scrollTo(mainBox.getScrollHeight()); -// }, 1000); stdinBox.focus(); // Render the screen screen.render() \ No newline at end of file