@cryptorubic/web3 1.1.0-alpha-stellar.8 → 1.1.0-alpha-stellar.9
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/package.json
CHANGED
|
@@ -35,7 +35,11 @@ class StellarAdapter extends abstract_adapter_1.AbstractAdapter {
|
|
|
35
35
|
try {
|
|
36
36
|
const resp = await this.public.simulateTransaction(tx);
|
|
37
37
|
//@ts-ignore
|
|
38
|
-
|
|
38
|
+
if (resp.error) {
|
|
39
|
+
return new bignumber_js_1.default(0);
|
|
40
|
+
}
|
|
41
|
+
//@ts-ignore
|
|
42
|
+
const rawRetval = resp.result.retval;
|
|
39
43
|
const balance = (0, stellar_sdk_1.scValToBigInt)(rawRetval);
|
|
40
44
|
return new bignumber_js_1.default(balance.toString());
|
|
41
45
|
}
|