@weblock-wallet/sdk 0.1.60 → 0.1.61
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +6 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +6 -1
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -104711,8 +104711,13 @@ var WalletService = class {
|
|
|
104711
104711
|
await LocalForage.delete(STORAGE_KEYS.share2(this.orgHost));
|
|
104712
104712
|
return txHash;
|
|
104713
104713
|
} catch (error) {
|
|
104714
|
+
if (error instanceof SDKError) {
|
|
104715
|
+
throw error;
|
|
104716
|
+
}
|
|
104717
|
+
const anyErr = error;
|
|
104718
|
+
const causeMsg = anyErr?.shortMessage || anyErr?.reason || anyErr?.message || anyErr?.error?.message || "Unknown error";
|
|
104714
104719
|
throw new SDKError(
|
|
104715
|
-
|
|
104720
|
+
`Transaction failed: ${causeMsg}`,
|
|
104716
104721
|
"TRANSACTION_FAILED" /* TRANSACTION_FAILED */,
|
|
104717
104722
|
error
|
|
104718
104723
|
);
|