refactor: Less verbose error messages

pull/153/head
Robert Dailey 2 years ago
parent eb9898fdd7
commit b3666ec3cb

@ -75,10 +75,11 @@ public abstract class BaseCommand : ICommand
break; break;
default: default:
Logger.Error(e, "Non-recoverable exception"); Logger.Error("{Message}", e.Message);
break; break;
} }
Logger.Debug(e, "Exception");
throw new CommandException("Exiting due to exception"); throw new CommandException("Exiting due to exception");
} }
finally finally

@ -34,8 +34,9 @@ public class CreateConfigCommand : BaseCommand
if (configFile.Exists) if (configFile.Exists)
{ {
throw new CommandException($"The file {configFile} already exists. Please choose another path or " + throw new CommandException(
"delete/move the existing file and run this command again."); $"The file {configFile} already exists. Please choose another path or delete/move the existing " +
"file and run this command again.");
} }
configFile.CreateParentDirectory(); configFile.CreateParentDirectory();

Loading…
Cancel
Save