@injectivelabs/wallet-cosmos 1.20.7 → 1.20.8
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/cjs/index.cjs +4 -1
- package/dist/esm/index.js +4 -1
- package/package.json +6 -6
package/dist/cjs/index.cjs
CHANGED
|
@@ -391,7 +391,10 @@ var CosmosWalletStrategy = class extends __injectivelabs_wallet_base.BaseConcret
|
|
|
391
391
|
const txRaw = (0, __injectivelabs_sdk_ts_core_tx.createTxRawFromSigResponse)(transaction);
|
|
392
392
|
if (!options.endpoints) throw new __injectivelabs_exceptions.CosmosWalletException(/* @__PURE__ */ new Error("You have to pass endpoints within the options to broadcast transaction"));
|
|
393
393
|
try {
|
|
394
|
-
|
|
394
|
+
var _options$onBroadcast;
|
|
395
|
+
const txHash = await cosmosWallet.broadcastTx(txRaw);
|
|
396
|
+
(_options$onBroadcast = options.onBroadcast) === null || _options$onBroadcast === void 0 || _options$onBroadcast.call(options, txHash);
|
|
397
|
+
return await (0, __injectivelabs_sdk_ts_core_tx.waitTxBroadcasted)(txHash, options);
|
|
395
398
|
} catch (e) {
|
|
396
399
|
if (e instanceof __injectivelabs_exceptions.TransactionException) throw e;
|
|
397
400
|
throw new __injectivelabs_exceptions.TransactionException(new Error(e.message), {
|
package/dist/esm/index.js
CHANGED
|
@@ -391,7 +391,10 @@ var CosmosWalletStrategy = class extends BaseConcreteStrategy {
|
|
|
391
391
|
const txRaw = createTxRawFromSigResponse(transaction);
|
|
392
392
|
if (!options.endpoints) throw new CosmosWalletException(/* @__PURE__ */ new Error("You have to pass endpoints within the options to broadcast transaction"));
|
|
393
393
|
try {
|
|
394
|
-
|
|
394
|
+
var _options$onBroadcast;
|
|
395
|
+
const txHash = await cosmosWallet.broadcastTx(txRaw);
|
|
396
|
+
(_options$onBroadcast = options.onBroadcast) === null || _options$onBroadcast === void 0 || _options$onBroadcast.call(options, txHash);
|
|
397
|
+
return await waitTxBroadcasted(txHash, options);
|
|
395
398
|
} catch (e) {
|
|
396
399
|
if (e instanceof TransactionException) throw e;
|
|
397
400
|
throw new TransactionException(new Error(e.message), {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@injectivelabs/wallet-cosmos",
|
|
3
|
-
"version": "1.20.
|
|
3
|
+
"version": "1.20.8",
|
|
4
4
|
"description": "Cosmos wallet strategies for use with @injectivelabs/wallet-core.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"author": {
|
|
@@ -45,11 +45,11 @@
|
|
|
45
45
|
"@cosmjs/proto-signing": "0.33.0",
|
|
46
46
|
"@cosmjs/stargate": "0.33.0",
|
|
47
47
|
"@keplr-wallet/types": "^0.12.296",
|
|
48
|
-
"@injectivelabs/exceptions": "1.20.
|
|
49
|
-
"@injectivelabs/
|
|
50
|
-
"@injectivelabs/
|
|
51
|
-
"@injectivelabs/
|
|
52
|
-
"@injectivelabs/ts-types": "1.20.
|
|
48
|
+
"@injectivelabs/exceptions": "1.20.8",
|
|
49
|
+
"@injectivelabs/wallet-base": "1.20.8",
|
|
50
|
+
"@injectivelabs/sdk-ts": "1.20.8",
|
|
51
|
+
"@injectivelabs/utils": "1.20.8",
|
|
52
|
+
"@injectivelabs/ts-types": "1.20.8"
|
|
53
53
|
},
|
|
54
54
|
"publishConfig": {
|
|
55
55
|
"access": "public"
|