Skip to content

Commit

Permalink
Merge pull request #23 from unoplatform/dev/jela/empty-version
Browse files Browse the repository at this point in the history
fix: Report more detailed exception on parsing errors
  • Loading branch information
jeromelaban authored Nov 5, 2024
2 parents d1f921b + daaee68 commit 6e115de
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/NvGet.Tools.Shared/Arguments/ConsoleArgError.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ public ConsoleArgError(string argument, ConsoleArgErrorType type, Exception e =
public string Message => Type switch
{
ConsoleArgErrorType.UnrecognizedArgument => "unrecognized argument: " + Argument,
ConsoleArgErrorType.ValueAssignmentError => "error while trying to assign value: " + Argument,
ConsoleArgErrorType.ValueParsingError => "error while trying to parse value: " + Argument,
ConsoleArgErrorType.ValueAssignmentError => $"error while trying to assign value: {Argument} (Exception: {Exception?.Message ?? "None"})",
ConsoleArgErrorType.ValueParsingError => $"error while trying to parse value: {Argument} (Exception: {Exception?.Message ?? "None"})",

_ => $"{Type}: " + Argument,
};
Expand Down

0 comments on commit 6e115de

Please sign in to comment.