mirror of
https://github.com/Tyrrrz/CliFx.git
synced 2025-10-25 15:19:17 +00:00
Standardize exception messages
This commit is contained in:
@@ -21,7 +21,7 @@ public class DefaultTypeActivator : ITypeActivator
|
||||
{
|
||||
throw CliFxException.InternalError(
|
||||
$"""
|
||||
Failed to create an instance of type `{type.FullName}`, could not access the constructor.
|
||||
Failed to create an instance of type `{type.FullName}` because an appropriate constructor is not available.
|
||||
Default type activator is only capable of instantiating a type if it has a public parameterless constructor.
|
||||
To fix this, either add a parameterless constructor to the type or configure a custom activator for the application.
|
||||
""",
|
||||
|
||||
@@ -86,7 +86,7 @@ internal partial class StackFrame
|
||||
// exception so that it's shown to the user.
|
||||
throw new FormatException(
|
||||
$"""
|
||||
Could not parse stacktrace:
|
||||
Failed to parse stacktrace:
|
||||
{stackTrace}
|
||||
"""
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user