From ebc32644db1daef13ed01d9cc515d816d770d880 Mon Sep 17 00:00:00 2001 From: ronaldsg Date: Wed, 3 Apr 2024 14:05:14 -0500 Subject: [PATCH] Handle Leather error on signing --- src/common/services/LeatherService.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/common/services/LeatherService.ts b/src/common/services/LeatherService.ts index 92022eaf..22fd5735 100644 --- a/src/common/services/LeatherService.ts +++ b/src/common/services/LeatherService.ts @@ -126,7 +126,11 @@ export default class LeatherService extends WalletService { resolve({ signedTx: signedPsbt }); }) .catch((e) => { - reject(e); + if (e.error.code) { + reject(new Error(e.error.message)); + } else { + reject(e); + } }); }); }