Error event handler
This commit is contained in:
parent
e80b080ed4
commit
b9671dbf21
@ -49,6 +49,12 @@ server.listen(port, () => {
|
||||
suBoard.connected = true;
|
||||
})
|
||||
|
||||
board.on('error', (err) => {
|
||||
console.error(chalk.red("\nError while connecting to Board"));
|
||||
console.error(chalk.red(err.message));
|
||||
console.log("Enter 'rs' to try again");
|
||||
})
|
||||
|
||||
board.on('exit', () => {
|
||||
console.log("Bye bye");
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user