Commit 4f897631 by Johannes Zellner

Check for error object

1 parent 9708e379
Showing with 1 additions and 1 deletions
......@@ -66,7 +66,7 @@ function login(uri) {
console.log('No such server %s'.red, server.bold);
process.exit(1);
}
if (error.code) {
if (error && error.code) {
console.log('Failed to connect to server %s'.red, server.bold, error.code);
process.exit(1);
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!