mirror of
https://github.com/bitinflow/localtunnel.git
synced 2026-10-31 20:59:08 +00:00
lt: better error handling
Let node handle the displaying of error and setting exit code.
This commit is contained in:
1 parent
9487797e02
commit
92caf2f204
1 file changed
+2
-3
+2
-3
@@ -27,14 +27,13 @@ var opt = {
|
||||
|
||||
lt_client(opt.port, opt, function(err, tunnel) {
|
||||
if (err) {
|
||||
console.error(err);
|
||||
return process.exit(1);
|
||||
throw err;
|
||||
}
|
||||
|
||||
console.log('your url is: %s', tunnel.url);
|
||||
|
||||
tunnel.on('error', function(err) {
|
||||
console.error(err);
|
||||
throw err;
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
Reference in new issue
Block a user