Command line connection errors print the exception

This commit is contained in:
Jordan Brown
2017-06-06 13:45:41 -04:00
committed by GitHub
parent 320f427e25
commit e6a64be097
+4 -4
View File
@@ -56,16 +56,16 @@ namespace TGCommandLine
var res = Server.VerifyConnection();
if (res != null)
{
Console.WriteLine("Unable to connect to service!");
Console.WriteLine("Unable to connect to service: " + res);
return ExitCode.ConnectionError;
}
try
{
return new RootCommand().Run(argsAsList);
}
catch
catch (Exception e)
{
Console.WriteLine("Service connection interrupted!");
Console.WriteLine("Error: " + e.ToString());
return ExitCode.ConnectionError;
};
}
@@ -127,4 +127,4 @@ namespace TGCommandLine
}
}
}
}
}