Tweak ToUserFriendlyString
MODIFY
WalletWasabi/Extensions/ExceptionExtensions.cs
WalletWasabi/Extensions/ExceptionExtensions.cs
@@ -35,7 +35,11 @@ public static class ExceptionExtensions
}
else
{
- if (ex is HwiException hwiEx)
+ if (ex is OperationCanceledException exception)
+ {
+ return exception.Message;
+ }
+ else if (ex is HwiException hwiEx)
{
if (hwiEx.ErrorCode == HwiErrorCode.DeviceConnError)
{
@@ -45,6 +49,10 @@ public static class ExceptionExtensions
{
return "The transaction was canceled on the device.";
}
+ else if (hwiEx.ErrorCode == HwiErrorCode.UnknownError)
+ {
+ return "Unknown error.\nMake sure the device is connected and isn't busy, then try again.";
+ }
}
foreach (KeyValuePair<string, string> pair in RpcErrorTools.ErrorTranslations)

Tweak ToUserFriendlyString